Package.json in a Nodejs project is the configuration file for your project. In the file we can configure multiple running script.
We can run the script with npm command in the console. Let’s fin configure our first custom script for app.js file.
"scripts": {
"start": "node ./app.js",
"test": "echo \"Error: no test specified\" && exit 1"
},
We can now run the script as npm start .