This project was bootstrapped with Create React App.
This is where all of our React components live. Notice the App
component
doesn't make API calls directly, but delegates that responsibility to the
apiClient
module.
The functions in this module are responsible for talking to the Express API server.
We use the browser built-in fetch
function to perform the HTTP
communication.
Notice that we always translate the reponse from JSON to JavaScript object using the Body.json() method.
See the Create React App documentation for an explanation of why we want to proxy our API server.