wip: fix some bugs around the rsx macro
This commit is contained in:
1 parent
9f7eb0f600
commit
339e450027
4 files changed
+57
-69
No files matched your search
@@ -0,0 +1 @@
|
||||
fn main( ) {}
|
||||
@@ -48,11 +48,11 @@ fn Row((cx, props): Component<RowProps>) -> DomTree {
|
||||
cx.render(rsx! {
|
||||
tr {
|
||||
td { class:"col-md-1", "{props.row_id}" }
|
||||
td { class:"col-md-1", on_click: move |_| { /* run onselect */ }
|
||||
td { class:"col-md-1", onclick: move |_| { /* run onselect */ }
|
||||
a { class: "lbl", "{props.label}" }
|
||||
}
|
||||
td { class: "col-md-1"
|
||||
a { class: "remove", on_click: {handler}
|
||||
a { class: "remove", onclick: {handler}
|
||||
span { class: "glyphicon glyphicon-remove remove" aria_hidden: "true" }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,31 +8,10 @@ use dioxus_html as dioxus_elements;
|
||||
fn main() {}
|
||||
|
||||
fn html_usage() {
|
||||
let r = html! {
|
||||
<div>
|
||||
"hello world"
|
||||
<div>
|
||||
</div>
|
||||
<div />
|
||||
"hello world"
|
||||
<Fragment>
|
||||
</Fragment>
|
||||
</div>
|
||||
};
|
||||
let r = rsx! {
|
||||
div {
|
||||
onclick: move |_| {}
|
||||
"hello world"
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
fn rsx_uage() {
|
||||
// let r = html! {
|
||||
// <Fragment>
|
||||
// "hello world"
|
||||
// "hello world"
|
||||
// "hello world"
|
||||
// "hello world"
|
||||
// </Fragment>
|
||||
// };
|
||||
}
|
||||
Reference in new issue
Block a user