Module wasm_react::hooks
source · [−]Expand description
This module contains bindings to React hooks.
Structs
Allows access to the underlying deferred value persisted with
use_deferred_value()
.
This struct specifies dependencies for certain hooks.
Allows access to the underlying JS data persisted with use_js_ref()
.
Allows access to the underlying memoized data persisted with use_memo()
.
Allows access to the underlying data persisted with use_ref()
.
Allows access to the underlying state data persisted with use_state()
.
Allows access to the transition state.
Functions
Returns a persisted, memoized callback.
Allows access to the current context value of the given context.
Returns the given value, or in case of urgent updates, returns the previous value given.
Runs a function which contains imperative code that may cause side-effects.
Returns a unique component ID which is stable across server and client.
This hook can persist JS data through the entire lifetime of the component.
Like use_effect()
, but it fires synchronously after all DOM mutations.
Returns a persisted, memoized value.
This is the main hook for persisting Rust data through the entire lifetime of the component.
Persist stateful data of the component.
Returns a stateful value for the pending state of the transition, and a function to start it.