Module sycamore::web

source ·
Expand description

Web support for Sycamore.

Modules§

  • Re-export of HTML event types from web-sys for convenience.
  • HTML and SVG tag definitions.
  • Utilities for client-side hydration in the browser.
  • Bindings to JavaScript’s standard, built-in objects, including their methods and properties.
  • Portal API.

Structs§

Traits§

  • Trait that is implemented by all GenericNode backends that render to HTML.

Functions§

  • Render the children of this component in a scope that will not be hydrated.
  • Only render the children of this component in the browser. The children are wrapped inside a <div> element to prevent conflicts with surrounding elements.
  • Render a View under a parent node by reusing existing nodes (client side hydration). Alias for hydrate_to with parent being the <body> tag.
  • Render a View under a parent node, in a way that can be cleaned up. This function is intended to be used for injecting an ephemeral sycamore view into a non-sycamore app (for example, a file upload modal where you want to cancel the upload if the modal is closed).
  • Render a View under a parent node by reusing existing nodes (client side hydration). For rendering under the <body> tag, use hydrate instead.
  • Queue up a callback to be executed when the component is mounted.
  • Alias for queueMicrotask.
  • Render a View into the DOM. Alias for render_to with parent being the <body> tag.
  • Render a View under a parent node, in a way that can be cleaned up. This function is intended to be used for injecting an ephemeral sycamore view into a non-sycamore app (for example, a file upload modal where you want to cancel the upload if the modal is closed).
  • Render a View under a parent node. For rendering under the <body> tag, use render instead.
  • Render a View into a static String. Useful for rendering to a string on the server side.
  • Render a View into a static String. Useful for rendering to a string on the server side.