node.js - 出现此错误 "UNMET PEER DEPENDENCY grunt@1.0.1"

标签 node.js heroku npm-install

我在通过“npm i”安装 grunt 时遇到问题。我也试过 0.4.5,但同样的错误。知道会发生什么吗?

为了帮助,这些是我的依赖项:

  "dependencies": {
    "arrify": "1.0.1",
    "as-jqplot": "1.0.8",
    "babel-runtime": "6.9.2",
    "bootstrap": "3.3.6",
    "bootstrap-slider": "9.1.1",
    "chart.js": "1.0.2",
    "chunk": "0.0.2",
    "clone": "1.0.2",
    "co": "4.6.0",
    "co-body": "4.2.0",
    "co-pg": "2.0.0",
    "expect": "1.20.2",
    "font-awesome": "4.6.3",
    "github": "2.2.0",
    "grunt": "1.0.1",
    "grunt-babel": "6.0.0",
    "grunt-bump": "0.8.0",
    "grunt-cli": "1.2.0",
    "grunt-contrib-concat": "1.0.1",
    "grunt-contrib-copy": "1.0.0",
    "grunt-contrib-imagemin": "1.0.1",
    "grunt-contrib-less": "1.3.0",
    "grunt-contrib-uglify": "2.0.0",
    "grunt-contrib-watch": "1.0.0",
    "grunt-eslint": "19.0.0",
    "grunt-jsonlint": "1.1.0",
    "grunt-plato": "1.2.1",
    "grunt-shell": "1.3.0",
    "jquery": "3.1.0",
    "koa": "1.2.1",
    "koa-bodyparser": "2.2.0",
    "koa-compress": "1.0.9",
    "koa-cors": "0.0.16",
    "koa-jade": "2.1.0",
    "koa-logger": "1.3.0",
    "koa-router": "5.4.0",
    "koa-sql-select": "1.1.1",
    "koa-static-folder": "0.1.6",
    "koa-useragent": "0.1.4",
    "load-grunt-tasks": "3.5.0",
    "mandrill-api": "1.0.45",
    "md5": "2.1.0",
    "moment": "2.14.1",
    "nconf": "0.8.4",
    "node-noop": "1.0.0",
    "node-persist": "0.0.11",
    "nodemon": "1.9.2",
    "pg": "6.0.3",
    "platform": "1.3.1",
    "plato": "1.6.0",
    "throng": "4.0.0",
    "time-grunt": "1.4.0",
    "typeahead.js": "0.11.1",
    "validator": "5.5.0"
  },
  "devDependencies": {
    "grunt-aws": "0.6.2"
  }

即使有错误,安装grunt。但是这个错误导致在 heroku 上的持续集成和部署失败。

最佳答案

使用 NPM 3.10.6,我在安装所有包时都没有遇到错误。

npm init
rm -rf ./node_modules
(copying your modules to the package.json)
npm i

没有错误。我建议你升级你的 npm

npm install -g npm

关于node.js - 出现此错误 "UNMET PEER DEPENDENCY grunt@1.0.1",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38552527/

相关文章:

javascript - 使用 Angular HttpClient 在 DELETE 请求完成后执行某些操作

ruby-on-rails - Heroku] 处理数据库

node.js - 如何在同一端口上运行express和geddy应用程序?

npm-install - 勒纳添加 : No packages found where <package> can be added

npm - 如何解决 npm 错误代码 : 254 in azure DevOps?

java - NodeJs 从 JAVA 解密 AES256 加密

javascript - 似乎无法使用 Python 和 Node.js 进行 POST

testing - 通过 ssh 连接时无法在远程 Windows 计算机上找到 TestCafe

node.js - docker 中使用 kerberos 和 openldap 进行 SSO

ruby-on-rails - 运行 heroku rake db :migrate 时出现 Heroku 错误