In this section, we're going to work on our environment to make our development process a little bit easier. The first thing that we're going to do is install a new package called nodemon. In our blockchain directory in our terminal, we will write the npm i nodemon --save command:
Whenever we make a change in one of our files and save it, this nodemon library will automatically restart our server for us so that we don't have to go back and forth from the terminal to our code to restart the server every time we make a change.
To use nodemon, we are going to open up our package.json file. Where it says "scripts", we're going to add a new script:
{
"name": "javaScript-blockchain",
"version": "1.0.0",
"description": "",
"main": "index.js"...