gpt4 book ai didi

Node.js NPM 安装

转载 作者:太空宇宙 更新时间:2023-11-04 00:56:46 26 4
gpt4 key购买 nike

我正在尝试他们网站上列出的 angularJS 教程来创建phonecat应用程序。它要求我安装 git、nodejs 等一些东西,我只需访问它们各自的网站并下载安装程序并运行它即可。现在,一开始它说安装完nodejs后,我必须在命令提示符下运行npm install,它将自动下载bower、karma、protractor、http-server。

现在的问题是,每当我从 nodejs 命令提示符或 Windows cmd 运行 npm install 时,都会出现大量错误。我不认为我有安装错误,我只是运行了安装程序。有人可以帮忙吗?错误是:

  • npm err install couldn't read dependencies
  • npm err windows_nt 6.1.7601
  • npm err argv "C:\program files\nodejs\\node.exe" "C:\progam files\nodejs\node_modules\npm\bin\npm-cli.js" "install"
  • npm err node v0.12.1
  • npm err npm v2.5.1
  • npm err path c:\users\SkyNet\package.json
  • npm err code ENOPACKAGEJSON
  • npm errno -4058
  • npm err package.json ENOENT, open 'c:\users\skynet\package.json'
  • npm err package.json this is most likley not a problem with npm itself.
  • npm err package.json npm can't find a package.json file in your current directory
  • npm err include the following file with an support request
  • npm err c:\users\skynet\npm-debug.log

最佳答案

您没有在包含 package.json 文件的文件夹中运行命令 npm install

您的node.js安装可能没有问题(如错误所示)

导航到包含 `package.json 的项目文件夹并执行命令。

关于Node.js NPM 安装,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29429889/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com