npm8中文文档
这将重新启动一个项目。相当于运行npm run-script restart。
npm run-script restart
如果当前项目在 package.json 中指定了 "restart" 脚本,则将运行以下脚本:
package.json
"restart"
如果它没有指定 "restart" 脚本,但它确实有 stop 和/或 start 脚本,则将运行以下脚本:
stop
start