2021-02-12 04:03:01 +00:00
|
|
|
fn main() {}
|
|
|
|
|
2021-07-07 17:51:55 +00:00
|
|
|
use dioxus_core as dioxus;
|
2021-03-23 03:52:54 +00:00
|
|
|
use dioxus_core::prelude::*;
|
2021-07-07 17:51:55 +00:00
|
|
|
mod dioxus_elements {
|
|
|
|
use super::*;
|
|
|
|
pub struct div;
|
|
|
|
impl DioxusElement for div {
|
|
|
|
const TAG_NAME: &'static str = "str";
|
|
|
|
const NAME_SPACE: Option<&'static str> = None;
|
|
|
|
}
|
|
|
|
}
|
2021-03-23 03:52:54 +00:00
|
|
|
|
2021-06-26 01:15:33 +00:00
|
|
|
static Example: FC<()> = |cx| {
|
2021-07-07 17:51:55 +00:00
|
|
|
let list = (0..10).map(|f| {
|
|
|
|
//
|
|
|
|
LazyNodes::new(move |f: NodeFactory| todo!())
|
|
|
|
});
|
|
|
|
cx.render(LazyNodes::new(move |cx| {
|
2021-06-26 01:15:33 +00:00
|
|
|
let bump = cx.bump();
|
2021-07-07 17:51:55 +00:00
|
|
|
dioxus_core::builder::ElementBuilder::new(&cx, "h1")
|
|
|
|
.children([
|
|
|
|
cx.text(format_args!("hello")),
|
|
|
|
cx.text(format_args!("hello")),
|
|
|
|
cx.fragment_from_iter(list),
|
|
|
|
])
|
2021-06-01 22:33:15 +00:00
|
|
|
.finish()
|
|
|
|
}))
|
|
|
|
};
|