From ede08f7ef619aa63aad8816954363a63a1fe3d99 Mon Sep 17 00:00:00 2001 From: Jeremy Wall Date: Sat, 20 Aug 2022 12:59:53 -0400 Subject: [PATCH] Use keyed for recipes now that we have stable keys --- web/src/components/recipe_selector.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web/src/components/recipe_selector.rs b/web/src/components/recipe_selector.rs index 545be65..25eb7d1 100644 --- a/web/src/components/recipe_selector.rs +++ b/web/src/components/recipe_selector.rs @@ -46,13 +46,14 @@ pub fn recipe_selector() -> View { (View::new_fragment( rows.get().iter().cloned().map(|r| { view ! { - div(class="grid") {Indexed(IndexedProps{ + div(class="grid") {Keyed(KeyedProps{ iterable: r.handle(), template: |(i, recipe)| { view! { RecipeSelection(RecipeCheckBoxProps{i: i, title: create_memo(move || recipe.get().title.clone())}) } }, + key: |r| r.0.clone(), })} } }).collect()