Day 25: Banish Boredom: Day 2
Wrap up
You've finished your first full JavaScript project! Congratulations!
The best way to get better at coding is to write your own code. Here are three ways you can improve this project.
- When the page loads have the button save "Bored" but then switch to "Still Bored" after the next activity suggestion loads.
- Make sure a user isn't shown an activity that is currently in their saved activities list. You can use the
key
property to check this. If the fetch returns an activity the user has saved then request another. - Save a list of all the activities the user has voted on and make sure not to show them the same one twice. Same basic principle as above, however you'll need to create another list in LocalStorage of all the ones the user has voted on.
You can find the full source code for this project on GitHub.