尝试使用npm install grunt --save-dev
在本地安装grunt时,我不断收到所有这些警告和依赖项问题。
PS C:\atomworkspace\angularProject\conFusion> npm install grunt --save-dev
conFusion@ C:\atomworkspace\angularProject\conFusion
+-- UNMET PEER DEPENDENCY grunt@1.0.1
+-- UNMET PEER DEPENDENCY grunt-contrib-clean@1.0.0 extraneous
+-- UNMET PEER DEPENDENCY grunt-contrib-coffee@~0.10.0
+-- UNMET PEER DEPENDENCY grunt-contrib-compass@~0.7.0
+-- UNMET PEER DEPENDENCY grunt-contrib-compress@~0.8.0
+-- UNMET PEER DEPENDENCY grunt-contrib-concat@~0.4.0
+-- UNMET PEER DEPENDENCY grunt-contrib-connect@~0.7.0
+-- UNMET PEER DEPENDENCY grunt-contrib-copy@~0.5.0
+-- UNMET PEER DEPENDENCY grunt-contrib-csslint@~0.2.0
+-- UNMET PEER DEPENDENCY grunt-contrib-cssmin@~0.9.0
+-- UNMET PEER DEPENDENCY grunt-contrib-handlebars@~0.8.0
+-- UNMET PEER DEPENDENCY grunt-contrib-htmlmin@~0.2.0
+-- UNMET PEER DEPENDENCY grunt-contrib-imagemin@~0.7.0
+-- UNMET PEER DEPENDENCY grunt-contrib-jade@~0.11.0
+-- UNMET PEER DEPENDENCY grunt-contrib-jasmine@~0.6.0
+-- UNMET PEER DEPENDENCY grunt-contrib-jshint@1.1.0 extraneous
+-- UNMET PEER DEPENDENCY grunt-contrib-jst@~0.6.0
+-- UNMET PEER DEPENDENCY grunt-contrib-less@~0.11.0
+-- UNMET PEER DEPENDENCY grunt-contrib-nodeunit@~0.3.0
+-- UNMET PEER DEPENDENCY grunt-contrib-qunit@~0.4.0
+-- UNMET PEER DEPENDENCY grunt-contrib-requirejs@~0.4.1
+-- UNMET PEER DEPENDENCY grunt-contrib-sass@~0.7.0
+-- UNMET PEER DEPENDENCY grunt-contrib-stylus@~0.15.1
+-- UNMET PEER DEPENDENCY grunt-contrib-symlink@~0.3.0
+-- UNMET PEER DEPENDENCY grunt-contrib-uglify@~0.4.0
+-- UNMET PEER DEPENDENCY grunt-contrib-watch@~0.6.0
`-- UNMET PEER DEPENDENCY grunt-contrib-yuidoc@~0.5.0
npm WARN grunt-contrib@0.11.0 requires a peer of grunt@~0.4.4 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-clean@~0.5.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-coffee@~0.10.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-compass@~0.7.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-compress@~0.8.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-concat@~0.4.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-connect@~0.7.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-copy@~0.5.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-csslint@~0.2.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-cssmin@~0.9.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-handlebars@~0.8.0 but none was installe
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-htmlmin@~0.2.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-imagemin@~0.7.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-jade@~0.11.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-jasmine@~0.6.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-jshint@~0.10.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-jst@~0.6.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-less@~0.11.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-nodeunit@~0.3.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-qunit@~0.4.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-requirejs@~0.4.1 but none was installed
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-sass@~0.7.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-stylus@~0.15.1 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-symlink@~0.3.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-uglify@~0.4.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-watch@~0.6.0 but none was installed.
npm WARN grunt-contrib@0.11.0 requires a peer of grunt-contrib-yuidoc@~0.5.0 but none was installed.
PS C:\atomworkspace\angularProject\conFusion>
这是我的package.json
:
{
"name": "conFusion",
"private": true,
"devDependencies": { "grunt": "^1.0.1" },
"engines": { "node": ">=0.10.0" }
}
答案 0 :(得分:0)
尝试全局安装grunt URLSession
答案 1 :(得分:0)
将 npm 版本降级到 6.x。它应该解决这个问题。 npm v7 会引发此类错误。