Skip to main content

Goal 2: Cross out the todo items when we save

Where we are now

When you tick a todo item, it gets saved to the database. But the item doesn’t get crossed out until you refresh the page.

User story

As a user, when I tick off a todo item, it should be crossed out straight away. When I un-tick a todo item, it should no longer be crossed out.

Technically speaking

The crossed-out styling is decided by the server, when it renders the todo item’s template. So when the user clicks a checkbox, the server needs to send back a freshly rendered todo item, and we need to put it on the page in place of the old one.