Function dioxus_core::hooks::use_ref [−][src]
pub fn use_ref<'a, T: 'static>(
ctx: &Context<'a>,
initial_state_fn: impl FnOnce() -> T + 'static
) -> &'a UseRef<T>
Store a mutable value between renders! To read the value, borrow the ref. To change it, use modify. Modifications to this value do not cause updates to the component Attach to inner context reference, so context can be consumed