npm start
from the root directory of your nodejs project, node will look for a scripts
object in your package.json
file. If found, it will look for a script with the key start
and run the command specified as its value.If your
package.json
does not have any scripts
object or if the scripts object does not have a start
key, it will run the command node server.js
instead.Npm scripts are pretty useful because they let you group together and run logically related commands. e.g. linters, minifiers etc.
No comments:
Post a Comment