npm global nodemon code example
Example 1: install nodemon
npm install nodemon
npm install -g nodemon
npm install nodemon --save-dev
Example 2: nodemon install globally
//Install nodemon on your project as dev-dependency
npm install nodemon --save-dev
//Update the package.json file
"scripts": {
"start": "node ./bin/www",
"devstart": "nodemon ./bin/www",
"serverstart": "DEBUG=your-folder-name:* npm run devstart"
},
//On Windows, use this command:
SET DEBUG=express-locallibrary-tutorial:* & npm run devstart
//restart server by typing this on cmd rs (restart)
rs