如何修复 npm 丢失的脚本

How do I fix npm missing script

PS C:\Users\LENOVO\Desktop\HTML PROJECTS\React\NewTodo-App> npm 启动 错误!缺少脚本:开始

npm 错误!此 运行 的完整日志可在以下位置找到: 错误! C:\Users\LENOVO\AppData\Roaming\npm-cache_logs21-09-05T09_29_42_788Z-debug.log

我每次 运行 npm start

时都会收到这个错误

去你的包裹。 json 并添加这个

"scripts": {
    "start": "node index.js"
  }