wip: prep to fix bug in create

This commit is contained in:
Jonathan Kelley committed 2022-11-15 23:22:41 -08:00
1 parent e09b6bf813
commit 04bc635ac5
14 files changed
+539 -57

No files matched your search

+18 -10
View File
@@ -6,15 +6,23 @@ fn main() {
fn app(cx: Scope) -> Element {
cx.render(rsx!(
// Use Map directly to lazily pull elements
(0..10).map(|f| rsx! { "{f}" }),
// Collect into an intermediate collection if necessary, and call into_iter
["a", "b", "c"]
.into_iter()
.map(|f| rsx! { "{f}" })
.collect::<Vec<_>>()
.into_iter(),
// Use optionals
Some(rsx! { "Some" }),
div { id: "123123123",
// Use Map directly to lazily pull elements
// (0..3).map(|f| rsx! { "{f}" }),
// Collect into an intermediate collection if necessary, and call into_iter
["a", "b", "c", "x", "y", "z"]
.into_iter()
.map(|f| rsx! { "{f}" })
.collect::<Vec<_>>()
.into_iter(),
["d", "e", "f"]
.into_iter()
.map(|f| rsx! { "{f}" })
.collect::<Vec<_>>()
.into_iter(),
// Use optionals
// Some(rsx! { "Some" }),
}
))
}