From 7d4cc291747cb1cc70e762aebee6a69b4391026d Mon Sep 17 00:00:00 2001 From: Jan Andrle Date: Sat, 14 Oct 2023 18:08:07 +0200 Subject: [PATCH] :bug: clear todos on remove (todosComponent example) --- examples/components/todosComponent.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/components/todosComponent.js b/examples/components/todosComponent.js index 68966f7..df43f7e 100644 --- a/examples/components/todosComponent.js +++ b/examples/components/todosComponent.js @@ -18,7 +18,7 @@ const className= style.host(todosComponent).css` export function todosComponent({ todos= [ "Task A" ] }= {}){ const todosS= S(todos.map(t=> S(t)), { add(v){ this.value.push(S(v)); }, - remove(i){ this.value.splice(i, 1)[0]; } + remove(i){ S.clear(this.value.splice(i, 1)[0]); } }); const name= "todoName";