sycamore

Module prelude

source
Expand description

The Sycamore prelude.

In most cases, it is idiomatic to use a glob import (aka wildcard import) at the beginning of your Rust source file.

use sycamore::prelude::*;

Re-exports§

Macros§

  • Debug the value of a variable to the JavaScript console if on wasm32. Otherwise logs it to stdout.
  • Log a message to the JavaScript console if on wasm32. Otherwise logs it to stdout.
  • A macro that expands to whether we are in DOM mode or not.
  • A macro that expands to whether we are in SSR mode or not.
  • A macro for ergonomically creating complex UI complex layouts.

Structs§

  • A special prop type that can be used to spread attributes onto an element.
  • A reference to a web_sys::Node. This allows imperative access to the node.
  • Represents a view tree.

Traits§

Functions§

Type Aliases§

  • A type alias for Children automatically selecting the correct node type.

Attribute Macros§

  • A macro for feature gating code that should only be run on the web.
  • A macro for feature gating code that should only be run on the server.
  • A macro for creating components from functions.

Derive Macros§

  • The derive macro for Props. The macro creates a builder-like API used in the view! macro.