mirror of
https://github.com/DioxusLabs/dioxus
synced 2024-11-24 13:13:06 +00:00
27 lines
561 B
Rust
27 lines
561 B
Rust
|
use dioxus::prelude::*;
|
||
|
|
||
|
fn main() {
|
||
|
dioxus::desktop::launch(app);
|
||
|
}
|
||
|
|
||
|
fn app(cx: Scope) -> Element {
|
||
|
cx.render(rsx! {
|
||
|
div {
|
||
|
button {
|
||
|
ondblclick: move |_| {
|
||
|
//
|
||
|
println!("double clicked!");
|
||
|
},
|
||
|
"Click me!"
|
||
|
}
|
||
|
input {
|
||
|
onfocusin: move |_| {
|
||
|
//
|
||
|
println!("blurred!");
|
||
|
},
|
||
|
"onblur": "console.log('blurred!')"
|
||
|
}
|
||
|
}
|
||
|
})
|
||
|
}
|