Steps for Implementing a More Robust Backend Development Architecture Part2
In part 1, we mainly looked at laying out the groundwork for the backend project, including setting up console logging (morgan), eslint, installing various dependencies, configuration for MongoDB connection, util files such as logger, creating the models I needed, coding the express app (app.js), and finally, populating the database with some initial data to work with. In this part, I’ll begin by documenting how I go about creating and testing the routes. Then, we’ll look at middleware and error handling. Finally, I’ll connect the frontend to the backend to make sure that all the data is being pulled correctly. ...