This is unreleased documentation for Yew Next version.
For up-to-date documentation, see the latest version on docs.rs.
yew_agent::oneshot

Function use_oneshot_runner

Source
pub fn use_oneshot_runner<'hook, T>() -> impl 'hook + Hook<Output = UseOneshotRunnerHandle<T>>
where T: Oneshot + 'static + 'hook,
Expand description

A hook to create a runner to an oneshot agent.

ยงNote

When used in function components and hooks, this hook is equivalent to:

pub fn use_oneshot_runner<T>() -> UseOneshotRunnerHandle<T>
where
    T: Oneshot + 'static,
{
    /* implementation omitted */
}