alternative.rs 499 B

1234567891011121314151617181920
  1. fn main() {}
  2. use dioxus::*;
  3. use dioxus_core as dioxus;
  4. use dioxus_core::prelude::*;
  5. static Example: FC<()> = |cx| {
  6. let list = (0..10).map(|f| LazyNodes::new(move |f| todo!()));
  7. cx.render(LazyNodes::new(move |cx| {
  8. let bump = cx.bump();
  9. cx.raw_element("div")
  10. .children([
  11. cx.text(format_args!("hello")),
  12. cx.text(format_args!("hello")),
  13. cx.fragment_from_iter(list),
  14. ])
  15. .finish()
  16. }))
  17. };