【问题标题】:npm install fails on clone of ag-grid-ng2-example克隆 ag-grid-ng2-example 时 npm 安装失败
【发布时间】:2016-09-18 17:14:04
【问题描述】:

我正在尝试在 Angular2 上试用 ag-Grid

我做了一个

git 克隆https://github.com/ceolter/ag-grid-ng2-example.git

我正在尝试按照自述文件中的说明进行操作 构建:

  • npm install

  • npm install tsd -g

  • tsd install es6-shim

  • npm run tsc

我在 README 的第一步中遇到错误

我有一个正常工作的 npm 并且有其他 Angular2 项目可以正常工作 但这是我第一次尝试 RC-1(一直在研究 beta-15 和 β-7) 我得到:

(注意我在下面粘贴的 https 之后添加了一个空格 防止它们成为链接)

npm http GET https://registry.npmjs.org/bootstrap

npm http GET https://registry.npmjs.org/lite-server

npm http GET https://registry.npmjs.org/concurrently

npm http GET https://registry.npmjs.org/es6-shim

npm http 404 https://registry.npmjs.org/angular/http/2.0.0-rc.1

npm http 404 https://registry.npmjs.org/angular/compiler/2.0.0-rc.1

npm 错误! 404 'angular' 不在 npm 注册表中。

npm 错误! 404 你应该让作者发布它

npm 错误! 404

npm 错误! 404注意,你也可以从一个安装

npm 错误! 404 tarball、文件夹或 http url 或 git url。

npm 错误!系统Linux 4.4.8-300.fc23.x86_64

npm 错误!命令“节点”“/bin/npm”“安装”

npm 错误! cwd /home/pwd/src/ag-grid-ng2-example

npm 错误!节点 -v v0.10.42

npm 错误! npm -v 1.3.6

npm 错误!代码 E404

npm http 200 https://registry.npmjs.org/ag-grid-enterprise

npm http 404 https://registry.npmjs.org/angular/platf...2.0.0-rc.1

npm http 404 https://registry.npmjs.org/angular/router/2.0.0-rc.1

npm http GET https://registry.npmjs.org/ag-grid-enter...-4.1.4.tgz

npm http 404 https://registry.npmjs.org/angular/core/2.0.0-rc.1

npm http 404 https://registry.npmjs.org/angular/route...2.0.0-rc.1

npm http 404 https://registry.npmjs.org/angular/platf...2.0.0-rc.1

npm http 404 https://registry.npmjs.org/angular/upgrade/2.0.0-rc.1

这是一个新的 git 克隆 最新提交 bad5317

【问题讨论】:

  • 只需要在markdown中缩进即可呈现为代码块

标签: angular npm-install ag-grid


【解决方案1】:

或者 Fedora 的过程是:

要获取最新的 node.js,请以 root 身份运行以下命令:

curl --silent --location https://rpm.nodesource.com/setup_4.x |重击-

yum remove -y nodejs npm

yum install -y nodejs

【讨论】:

    【解决方案2】:

    这可能是由于您系统上当前版本的 node.js。您需要升级您的节点和 npm 安装。至少,我刚才在使用节点 0.10 和 npm 时遇到了同样的错误,现在我已经升级到节点 6.0.0 和 npm 3.8.6,然后一切正常。 要更新节点,您可以从官方网站安装最新版本的节点。

    NodeJs Download

    对于 Fedora,流程是:

    要获取最新的 node.js,请以 root 身份运行以下命令:

    curl --silent --location https://rpm.nodesource.com/setup_4.x |重击-

    yum remove -y nodejs npm

    yum install -y nodejs

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-09-08
      • 1970-01-01
      • 1970-01-01
      • 2020-02-03
      • 2017-02-04
      • 2012-12-07
      相关资源
      最近更新 更多