pub fn use_timeout<F>(delay_ms: u32, callback: F)where
F: FnOnce() + 'static,Expand description
Schedules callback to run once, delay_ms milliseconds from now.
The callback is dropped if the component unmounts before the delay elapses, so a timeout cannot fire into a component that is gone.
ยงArguments
u32- The delay in milliseconds.F- The callback to run.