nodemon not working properly

后端 未结 13 1272
我在风中等你
我在风中等你 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:33

    Here's what I did to make nodemon update correctly:

    nodemon index.js -L
    

    The -L flag stands for legacyWatch, here's an explanation from the official doc:

    In some networked environments (such as a container running nodemon reading across a mounted drive), you will need to use the legacyWatch: true which enables Chokidar's polling.

    https://www.npmjs.com/package/nodemon#application-isnt-restarting

提交回复
热议问题