Remove argument from use_hook closure (#496)
Also; update docs for said function
This commit is contained in:
1 parent
6ea076fa7f
commit
d734dc5b46
29 files changed
+53
-55
No files matched your search
@@ -23,7 +23,7 @@ fn main() {
|
||||
}
|
||||
|
||||
fn app(cx: Scope) -> Element {
|
||||
let text = cx.use_hook(|_| vec![String::from("abc=def")]);
|
||||
let text = cx.use_hook(|| vec![String::from("abc=def")]);
|
||||
|
||||
let first = text.get_mut(0).unwrap();
|
||||
|
||||
|
||||
Reference in new issue
Block a user