remove cx.render
This commit is contained in:
159 files changed
+600
-658
No files matched your search
@@ -69,10 +69,10 @@ fn Blog() -> Element {
|
||||
|
||||
#[component]
|
||||
fn Home() -> Element {
|
||||
let mut count = use_state(|| 0);
|
||||
let text = use_state(|| "...".to_string());
|
||||
let mut count = use_signal(|| 0);
|
||||
let text = use_signal(|| "...".to_string());
|
||||
|
||||
cx.render(rsx! {
|
||||
rsx! {
|
||||
Link {
|
||||
to: Route::Blog {},
|
||||
"Go to blog"
|
||||
@@ -82,5 +82,5 @@ fn Home() -> Element {
|
||||
button { onclick: move |_| count += 1, "Up high!" }
|
||||
button { onclick: move |_| count -= 1, "Down low!" }
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user