Skip to main content

retain

Function retain 

Source
pub fn retain<F, T>(init: F) -> State<T>
where F: FnOnce() -> T, T: Send + Sync + 'static,
Expand description

Initializes state by call order during a build, retaining it until unmount.

Use retain_with_key for reordered collections; see State for access and lifetime rules.