nodemon not working properly

后端 未结 13 1670
我在风中等你
我在风中等你 2021-02-01 05:20

I am running my nodejs app by npm start

I just installed nodemon by sudo npm install -g nodemon so that i can get my server restarted when i s

13条回答
  •  没有蜡笔的小新
    2021-02-01 05:49

    Add following code in your code

    1. app.js

      app.listen(3000, function(){
          console.log("info",'Server is running at port : ' + 3000);
      });
      
    2. package.json

      nodemon app.js 
      

    Then run npm start from the command line.

提交回复
热议问题