Check Off and Remove To-dos
Write the code, see it run, pass the checks.
The problem
- medium
- Code
The starter shows three to-dos, each with a checkbox and a Remove button, and a summary reading "0 of 3 done". Make ticking a checkbox mark that to-do done, Remove delete just that to-do, and keep the summary right ("1 of 2 done"). Update state by making new arrays and objects, never by changing the existing ones.
Your code must pass
- Ticking a to-do marks it done in the summary
- Unticking it marks it not done again
- Remove deletes only that to-do
- The summary counts what's left