pub enum UseStorageKind {
Local,
Session,
}Expand description
Which browser storage a UseStorage handle reads and writes.
The two storages differ in lifetime, not in shape: both are plain string maps on the window.
Variants§
Local
window.localStorage — survives a reload and a browser restart.
Session
window.sessionStorage — survives a reload, gone with the tab.
Trait Implementations§
Source§impl Clone for UseStorageKind
impl Clone for UseStorageKind
impl Copy for UseStorageKind
Source§impl Debug for UseStorageKind
impl Debug for UseStorageKind
impl Eq for UseStorageKind
Source§impl PartialEq for UseStorageKind
impl PartialEq for UseStorageKind
impl StructuralPartialEq for UseStorageKind
Auto Trait Implementations§
impl Freeze for UseStorageKind
impl RefUnwindSafe for UseStorageKind
impl Send for UseStorageKind
impl Sync for UseStorageKind
impl Unpin for UseStorageKind
impl UnsafeUnpin for UseStorageKind
impl UnwindSafe for UseStorageKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more