NPM启动错误

时间:2018-07-15 08:06:55

标签: node.js angular npm

我是新手。 我在“ npm start”上遇到这些错误

npm ERR! Windows_NT 10.0.17134
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\lenovo\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "start"
npm ERR! node v6.14.0
npm ERR! npm  v3.10.10

npm ERR! missing script: start
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

npm ERR! Please include the following file with any support request:
npm ERR!     C:\Users\lenovo\npm-debug.log

2 个答案:

答案 0 :(得分:1)

您的package.json没有脚本start

示例:

{
    "name: "my project",

    /* you should create scripts same here */
    "scripts":{
        "start": "node index.js"  /* index.js is file you want run */
    }
}

答案 1 :(得分:0)

我认为您的lenovo文件夹中没有package.json文件

错误说

> npm ERR! enoent ENOENT: no such file or directory, open
> 'C:\Users\lenovo\package.json'
  

start your angular journey from here