- type your code in a file say index.js
- run it with nodejs as node index.js in command prompt.
- install nodemon with npm install -g nodemon
- Type your code in a file say index.js
- Instead of running it with node, run it with nodemon index.js