docs: update local examples and docs to support new syntaxes
This commit is contained in:
1 parent
e495b09bf1
commit
4de16c4779
118 files changed
+520
-1154
No files matched your search
@@ -31,21 +31,3 @@ fn bleat() {
|
||||
let blah = String::from("asd");
|
||||
eat(&blah);
|
||||
}
|
||||
|
||||
// struct Lower {}
|
||||
|
||||
// #[derive(Clone, Copy)]
|
||||
// struct Upper {}
|
||||
// impl std::ops::Deref for Upper {
|
||||
// type Target = Lower;
|
||||
|
||||
// fn deref(&self) -> &Self::Target {
|
||||
// todo!()
|
||||
// }
|
||||
// }
|
||||
|
||||
// fn mark(f: &Lower) {}
|
||||
// fn bark() {
|
||||
// let up = Upper {};
|
||||
// mark(&up);
|
||||
// }
|
||||
@@ -1,16 +1,10 @@
|
||||
use dioxus::prelude::*;
|
||||
use dioxus_core as dioxus;
|
||||
use dioxus_core_macro::*;
|
||||
use dioxus_hooks::use_state;
|
||||
use dioxus_html as dioxus_elements;
|
||||
|
||||
fn main() {}
|
||||
|
||||
fn App(cx: Scope<()>) -> Element {
|
||||
let color = use_state(&cx, || "white");
|
||||
|
||||
cx.render(rsx!(
|
||||
div { onclick: move |_| color.set("red"), "red" }
|
||||
div { onclick: move |_| color.set("blue"), "blue" }
|
||||
))
|
||||
todo!()
|
||||
}
|
||||
Reference in new issue
Block a user