pub struct Deps<T>(/* private fields */);
Expand description
This struct specifies dependencies for certain hooks.
§Example
use_effect(|| {
log("This effect will be called every time `self.id` or `state.counter` changes.");
}, Deps::some((self.id, state.counter)));
Implementations§
Trait Implementations§
impl<T: Copy> Copy for Deps<T>
impl<T> StructuralPartialEq for Deps<T>
Auto Trait Implementations§
impl<T> Freeze for Deps<T>where
T: Freeze,
impl<T> RefUnwindSafe for Deps<T>where
T: RefUnwindSafe,
impl<T> Send for Deps<T>where
T: Send,
impl<T> Sync for Deps<T>where
T: Sync,
impl<T> Unpin for Deps<T>where
T: Unpin,
impl<T> UnwindSafe for Deps<T>where
T: UnwindSafe,
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