MERN Stack Web Application Template
MERN Stack Template
The MERN stack is made up of:
- MongoDB: A document-oriented database used to store the application's data
- Express.js: A Node.js framework used to create the backend.
- React: A library created by Facebook used to create the UI components of the application
This template already comes with a basic version of the classic to-do list application. Important features include:
- MongoDB database
- REST API
- React frontend
Using this template
In the backend repl, create a '.env' file and set a variable called 'DB' equal to your MongoDB database. Then, in the frontend repl, replace the backend variable in
config.js with the url to your backend repl. Once you've done these two things, you can start working on your new web application.
I am getting an error about sending too many headers: Request received
Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client
you could try connecting express and react together (I've done it it's just extremely slow since React is such a space drainer), but I do believe it comes with some minor downsides like caches and stuff