In this lesson we’ll install json-server
as a dependency of our project so we can explore making API calls in a Redux-friendly way. We’ll update the scripts in package.json
to allow us to run the server and verify it is responding by issuing a curl
command.
How come you didn't add json-server package to dev dependencies?
How come you didn't add json-server package to dev dependencies?
Because for this particular example, we deploy the entire thing to a server in the last video and json-server
is part of the "production" deployment. Not something I would use for a real production app, but getting into setting up a real server was beyond the scope of this course.
Copy and paste and using a setup that cuts off half of the code. Good job!
Copy and paste and using a setup that cuts off half of the code. Good job!
The lesson includes a link to the code. Here is the direct link to that file:
https://github.com/eggheadio-projects/egghead_react_redux_course/blob/15-json-server/db.json