update large table example to demonstrate new .html() method instead of 'for'
@@ -57,11 +57,10 @@ fn view_row(selected: Option<(u32, u32)>, row: u32) -> Html<Model> {
impl Renderable<Model> for Model {
fn view(&self) -> Html<Self> {
+ use yew::virtual_dom::vnode::ToHtmlAdaptor;
html! {
<table>
- {for (0..99).map(|row| {
- view_row(self.selected, row)
- })}
+ { (0..99).map(|row| view_row(self.selected, row)).html() }
</table>
}
}
