ROTTEN TOMATILLOS: INITIAL PLAN
Jessica and Cameron
What components do you envision needing?
- App class component
- MovieContainer functional component (container for movie posters on home view)
- MoviePoster component functional?
- MovieDetails component functional?
- Search bar (class component) - extension if time allows
Also, possibly:
- Rating component?
- Revenue/Budget comparison component?
Where will data be stored?
- Initially, movie data will be imported from a hard-coded file - later we'll transition to fetching using a network request
- Dummy or API data will be used to initialize the App component - all movie data stored in state of App component
- State will also be needed if we integrate a search bar
How will information be passed around?
- App will hold all movie data in state, either from the hard-coded files for dummy data or data fetched from the API server
- On page load, App will instantiate a new MovieContainer component, passing in the movie data from state
- MovieContainer will then iterate through that array of Movie data, using each element to instantiate a new MoviePoster component
- MovieDetails will need to accept props to display that specific movie's detailed information.
When a user clicks on a MoviePoster component, how will React identify and display the correct info for MovieDetails? Will MoviePoster need to be a class component for this?