pub struct LifecycleHooks { /* private fields */ }
Expand description
Lifecycle hook options for components
Implementations§
Source§impl LifecycleHooks
impl LifecycleHooks
Sourcepub fn on_mount<F>(&mut self, callback: F)
pub fn on_mount<F>(&mut self, callback: F)
Register a callback for when the component is mounted
Sourcepub fn on_before_update<F>(&mut self, callback: F)
pub fn on_before_update<F>(&mut self, callback: F)
Register a callback for before the component updates
Sourcepub fn on_before_unmount<F>(&mut self, callback: F)
pub fn on_before_unmount<F>(&mut self, callback: F)
Register a callback for before the component unmounts
Sourcepub fn on_unmount<F>(&mut self, callback: F)
pub fn on_unmount<F>(&mut self, callback: F)
Register a callback for when the component unmounts
Trait Implementations§
Source§impl Debug for LifecycleHooks
impl Debug for LifecycleHooks
Source§impl Default for LifecycleHooks
impl Default for LifecycleHooks
Source§fn default() -> LifecycleHooks
fn default() -> LifecycleHooks
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for LifecycleHooks
impl !RefUnwindSafe for LifecycleHooks
impl Send for LifecycleHooks
impl Sync for LifecycleHooks
impl Unpin for LifecycleHooks
impl !UnwindSafe for LifecycleHooks
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