node+express build mall project (1-project build)
1: Download node
- The blogger has installed the node version: v14.14.1 node official website: you can choose the same version as the blogger
2: Install express
- Generally choose global installation:
npm install -g express
3: Install express cli to build a project with one click
npm install -g express-generator
Use ejs template engine to create node project: express --view=ejs node-demo
4: Installation dependencies
- Enter the project directory npm i to install the dependencies
- Use the command npm run start to start the project
-Install hot update to automatically update the project
- npm install nodemon -g --save-dev
- After the download is complete, replace start in scripts in the package.json file with the following
- Now restart your project and compile as much as you want