Function dioxus_storage::use_persistent
source · pub fn use_persistent<T: Serialize + DeserializeOwned + Default + 'static>(
cx: &ScopeState,
key: impl ToString,
init: impl FnOnce() -> T
) -> &UsePersistent<T>Expand description
A persistent storage hook that can be used to store data across application reloads.
Depending on the platform this uses either local storage or a file storage