π·οΈ backlog for sprint 2
JS3-Module-Project π
Level 300: Swap back to your old codebase π Clone
Level 300
For level 300, you should switch back to your original codebase.
You should have merged someone else’s level 200 implementation.
Once again, compare their implementation to yours. Think:
- How is it different?
- What do you prefer about your implementation?
- What do you prefer about their implementation?
- What did you learn that you didn’t know before?
Have a discussion about your answers to these questions. In class, together, give a 3 minute talk about your conclusions. Do this in small groups so you can be done in 15 minutes.
Refactoring
Like with level 200, feel free to change anything in your codebase which you think will make it easier to work with, or to build new features.
Have your partner review any changes you have, and make sure they understand them.
Adding new functionality
Level 300 is about getting rid of our static data from episodes.js
, and instead using an API.
Requirements
- You must delete the
episodes.js
file from your repository. - Your website must still work the same, but by using a
fetch
request to https://api.tvmaze.com/shows/82/episodes. This URL should serve the exact same content as was returned bygetAllEpisodes
inepisodes.js
. - You must fetch this URL only once per visit to your website. You should not re-fetch when someone searches, scrolls, or selects an episode from the drop-down.
- If you don’t have data yet, you should show something to tell the user to wait for the data.
- If an error occurred loading the data, notify the user.
- Note: real users don’t look in the console -
console.log
orconsole.error
are not sufficient for this requirement. - You will need to simulate an error to test this out yourself.
Documentation
You can see that this endpoint has been documented here: https://www.tvmaze.com/api#show-episode-list
- π― Topic Code Review
- π― Topic Iteration
- π― Topic Requirements
- π― Topic Teamwork
- π Week 2
Level 200: Swap Codebases π Clone
Level 200
For level 200, you are not allowed to work on the same codebase as you worked on for level 100.
Swap repos with a random person in your class. You do not need to coordinate your schedules.
Fork their GitHub repository to your GitHub username. You will need to give it a different name (e.g. JS3-Module-Project-Partner
), because you already have a repo named JS3-Module-Project
.
Clone their repository to your laptop.
Look at their level 100 implementation.
Compare their implementation to yours. Think:
- How is it different?
- What do you prefer about your implementation?
- What do you prefer about their implementation?
- What did you learn that you didn’t know before?
They should do the same with your repository.
Have a discussion about your answers to these questions. In class, together you should give a talk for 5 minutes about your conclusions. (Do this in small groups - we don’t want to take all day).
Refactoring
Before implementing new features, take some time to change the codebase you’re going to build level 200 in. Change anything you think will make it easier to add more features.
Some example ideas that you may want to think about:
- Could any variables or functions have more clear names, to help you understand what they do?
- Would extracting functions help make some code easier to understand?
Make a pull request to your partner’s repo with any changes you want to make. Have them review, and when happy, merge your PR.
Adding new functionality
Level 200 is all about being able to filter episodes.
Search
Add a live search input which meets the following requirements:
When a user types a search term into the search box:
- Only episodes whose summary OR name contains the search term should be displayed
- The search should be case-insensitive
- The display should update immediately after each keystroke changes the input
- Display how many episodes match the current search
- If the search box is cleared, all episodes should be shown
Send a pull request to your partner’s repo with this functionality. Have them review, and when happy, merge your PR.
Screenshot of minimal version
Note: Provided your project meets the above requirements, it can look however you want.
Here is one example layout.
Episode selector
Add a select
drop-down which lets the user jump quickly to a particular episode, with the following requirements:
- The select input should list all episodes in the format: “S01E01 - Winter is Coming”
- When the user makes a selection, they should be taken directly to that episode in the list
- Bonus: if you prefer, when the select is used, ONLY show the selected episode. If you do this, be sure to provide a way for the user to see all episodes again.
Send a pull request to your partner’s repo with this functionality. Have them review, and when happy, merge your PR.
Screenshot of minimal version
Note: Provided your project meets the above requirements, it can look however you want.
Here is one example layout.
- π― Topic Code Review
- π― Topic Iteration
- π― Topic Teamwork
- π Week 2