mirror of
https://github.com/leptos-rs/leptos
synced 2024-11-10 14:54:16 +00:00
Make it clearer which hooks are reactive
This commit is contained in:
parent
d8cfa973f1
commit
f9ff54249a
1 changed files with 2 additions and 2 deletions
|
@ -29,10 +29,10 @@ where
|
|||
T: PartialEq + std::fmt::Debug + Clone,
|
||||
{
|
||||
let route = use_route(cx);
|
||||
create_memo(cx, move |_| T::from_map(&route.params()))
|
||||
create_memo(cx, move |_| route.params().with(T::from_map))
|
||||
}
|
||||
|
||||
pub fn use_params_map(cx: Scope) -> ParamsMap {
|
||||
pub fn use_params_map(cx: Scope) -> Memo<ParamsMap> {
|
||||
let route = use_route(cx);
|
||||
route.params()
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue