- nodemon.json
{
"ignore": [
"dist",
".git",
".svn",
".dart_toool/**"
],
"verbose": true,
"env": {
"NODE_ENV": "development"
},
"watch": [
"./bin/*.dart",
"./lib/*.dart"
],
"quiet": true,
"events": {
"restart": "bash .sh/nodemon_watch.sh"
}
}
- package.json
{
"scripts": {
"start": "npm run watch",
"watch": "nodemon --exec \"dart\" bin/cli.dart"
},
}
- 运行命令
npm start