From the course: Building Modern Projects with React

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Solution: Adding a Redux flow

Solution: Adding a Redux flow

From the course: Building Modern Projects with React

Start my 1-month free trial

Solution: Adding a Redux flow

- Okay I'm going to show you how I solve this challenge. Keep in mind that the code I'm going to write in this video will continue to be a part of this project, so if you did yours a little differently, you might want to rewrite it to make it more similar to mine or just keep in mind that things like variable names in your project might be a little different going forward. So with that in mind, I followed a very similar flow as what we used for removing and creating new todos. I started off with actions.js, and I added a new action at the bottom, I stated off by creating an action type, I said export const, mark todo as completed, and set that equal to a string, mark todo as completed. And then I made the action creater. Export const, mark todo as completed, and I made that take the text of the todo that we wanted to mark as completed as an argument. So text, and then that's going to return an action with the type.…

Contents