【问题标题】:Is there a way that I can clear this npm error有没有办法可以清除这个 npm 错误
【发布时间】:2020-09-09 07:07:35
【问题描述】:
$npm start
npm ERR! code ENOENT
npm ERR! syscall open
npm ERR! path /home/gatua/package.json
npm ERR! errno -2
npm ERR! enoent ENOENT: no such file or directory, open '/home/gatua/package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent 

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/gatua/.npm/_logs/2020-05-22T12_23_50_208Z-debug.log

【问题讨论】:

  • 您是否在您的 package.json 文件所在的目录中运行 npm start
  • 你有created package.json吗?

标签: node.js npm


【解决方案1】:

您只是在项目文件夹之外运行npm 命令。如果不是这样。首先,您需要通过运行npm init 命令创建 package.json 文件。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-01-06
    • 2020-12-13
    • 2015-09-23
    • 1970-01-01
    • 2016-01-20
    • 2022-09-27
    相关资源
    最近更新 更多