- The good news here is that you've seen this all before!
- Everything should be working the way you previously had built this project, with one major difference, we are no longer sending out HTTP requests for you.
- You are now tasked to fix this very problem.
- Fork this repository, then clone your fork.
- Run
yarn
to download dependencies. - Run the server using
yarn start
ornode server.js
. - In a separate terminal cd into the
client
folder and runyarn install
to download dependencies. - Still inside the
client
folder runyarn start
to run the client application.
- Notice that in the
MoviesList
component ourcomponentDidMount
is missing it's guts. - Without peeking back at the original assignment, fill this in to retrieve the list of movies once again.
- Be sure to set them on state so that your component can render the list.
- Now that we have our movies rendering to the page, head over to the
Movie
component. - Notice that our
fetchMovie
function is no longer making any HTTP Request. Fix it. - Once again no peeking. Doing this on your own will help you out.
- Build out a form for adding a movie to your movie list.
- You'll need a new
route
potentially/movie/add
and you'll need to mount a new component potentiallyMovieCreate
- Make your styles match the rest of the app.
- Consider all of the following data:
{
id: 5,
title: 'Tombstone',
director: 'George P. Cosmatos',
metascore: 89,
stars: ['Kurt Russell', 'Bill Paxton', 'Sam Elliot'],
}
- The information found here is what you would need to pull off of a form from an input
- NOTE The
id
field is auto generated on the server, so you don't need to send anid
up with your information.