pub fn use_api_dynamic<'hook, R>() -> impl 'hook + Hook<Output = DynLazyResponse<R>>where
R: 'hook + Request + 'static,
Expand description
Useful when not wanting to run a request on mount, e.g. for a logout button You may run the request multiple times through multiple emits of the callback
By using the dynamic hook you can build the request with its parameters at runtime
ยงNote
When used in function components and hooks, this hook is equivalent to:
pub fn use_api_dynamic<R: Request + 'static>() -> DynLazyResponse<R> {
/* implementation omitted */
}