在此package.json
上运行npm install时{
"author": ", Inc.",
"name": "-angular2-template",
"version": "0.2.0",
"description": "Angular 2 Project Template. Webpack, ES6, Sass, Karma.",
"bugs": {
"url": "https://dev..net//-angular-template/issues"
},
"repository": {
"type": "git",
"url": "git@dev..net:/-angular-template.git"
},
"scripts": {
"start": "concurrently -k -r \"npm run webpack:w\" \"npm run sass:w\" \"npm run lite\"",
"build": "NODE_ENV='production' npm run webpack:b && npm run sass:b",
"webpack:b": "webpack",
"webpack:w": "webpack -w",
"sass": "node-sass --source-map true src/scss/index.scss build/styles.css",
"sass:b": "node-sass --output-style compressed src/scss/index.scss build/styles.css",
"sass:w": "npm run sass; node-sass --source-map true -w src/scss/index.scss build/styles.css",
"lite": "lite-server",
"postinstall": "typings install",
"typings": "typings"
},
"dependencies": {
"@angular/common": "2.0.0-rc.4",
"@angular/compiler": "2.0.0-rc.4",
"@angular/core": "2.0.0-rc.4",
"@angular/platform-browser": "2.0.0-rc.4",
"@angular/platform-browser-dynamic": "2.0.0-rc.4",
"@angular/forms": "^0.3.0",
"@angular/http": "2.0.0-rc.4",
"@angular/router": "3.0.0-beta.1",
"@angular/upgrade": "2.0.0-rc.4",
"angular2-cookie": "^1.2.2",
"bootstrap": "^3.3.7",
"firebase": "^3.3.0",
"js-data": "^3.0.0-rc.2",
"js-data-http": "^3.0.0-beta.8",
"lodash": "^4.6.1",
"ng2-bootstrap": "^1.0.24",
"reflect-metadata": "^0.1.3",
"rxjs": "5.0.0-beta.6",
"tslint": "^3.13.0",
"zone.js": "^0.6.12"
},
"devDependencies": {
"angular2-template-loader": "^0.4.0",
"autoprefixer": "^6.3.4",
"babel-preset-es2015": "^6.9.0",
"babel-register": "^6.9.0",
"browser-sync-webpack-plugin": "^1.1.0",
"codelyzer": "0.0.25",
"concurrently": "^2.0.0",
"css-loader": "^0.23.1",
"extract-text-webpack-plugin": "^1.0.1",
"file-loader": "^0.8.5",
"html-loader": "^0.4.3",
"html-webpack-plugin": "^2.15.0",
"jasmine-core": "^2.4.1",
"karma": "^0.13.22",
"karma-jasmine": "^0.3.8",
"karma-phantomjs-launcher": "^1.0.0",
"karma-sourcemap-loader": "^0.3.7",
"karma-webpack": "^1.7.0",
"lite-server": "^2.2.0",
"node-sass": "^3.4.2",
"null-loader": "^0.1.1",
"phantomjs-prebuilt": "^2.1.7",
"postcss": "^5.0.21",
"postcss-loader": "^0.9.1",
"raw-loader": "^0.5.1",
"sass-loader": "^4.0.0",
"style-loader": "^0.13.1",
"ts-loader": "^0.8.1",
"tslint-eslint-rules": "^1.3.0",
"tslint-loader": "^2.1.5",
"typescript": "^1.8.10",
"typings": "^1.0.4",
"webpack": "^1.13.0"
}
}
我收到以下错误..
typings WARN deprecated 8/18/2016: "registry:dt/node#4.0.0+20160509154515" is deprecated (updated, replaced or removed)
typings WARN deprecated 7/25/2016: "registry:dt/core-js#0.0.0+20160317120654" is deprecated (updated, replaced or removed)
typings WARN deprecated 6/21/2016: "registry:dt/jasmine#2.2.0+20160505161446" is deprecated (updated, replaced or removed)
typings WARN deprecated 7/24/2016: "registry:dt/webpack#1.12.9+20160523035535" is deprecated (updated, replaced or removed)
├── core-js (global)
├── jasmine (global)
├── moment (global)
├── node (global)
├── source-map (global)
├── uglify-js (global)
└── webpack (global)
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\angularfire2 requires @angular/common@'^2.0.0-rc.5' but will load
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\@angular\common,
npm WARN unmet dependency which is version 2.0.0-rc.4
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\angularfire2 requires @angular/compiler@'^2.0.0-rc.5' but will load
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\@angular\compiler,
npm WARN unmet dependency which is version 2.0.0-rc.4
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\angularfire2 requires @angular/core@'^2.0.0-rc.5' but will load
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\@angular\core,
npm WARN unmet dependency which is version 2.0.0-rc.4
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\angularfire2 requires @angular/platform-browser@'^2.0.0-rc.5' but will load
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\@angular\platform-browser,
npm WARN unmet dependency which is version 2.0.0-rc.4
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\angularfire2 requires @angular/platform-browser-dynamic@'^2.0.0-rc.5' but will load
npm WARN unmet dependency C:\Users\Modal\ng2-crm-revamp\node_modules\@angular\platform-browser-dynamic,
npm WARN unmet dependency which is version 2.0.0-rc.4
npm ERR! Windows_NT 10.0.10586
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! node v4.5.0
npm ERR! npm v2.15.9
npm ERR! code EPEERINVALID
npm ERR! peerinvalid The package @angular/common@2.0.0-rc.4 does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer @angular/platform-browser@2.0.0-rc.4 wants @angular/common@^2.0.0-rc.4
npm ERR! peerinvalid Peer @angular/platform-browser-dynamic@2.0.0-rc.4 wants @angular/common@^2.0.0-rc.4
npm ERR! peerinvalid Peer @angular/forms@0.3.0 wants @angular/common@^2.0.0-rc.5
npm ERR! peerinvalid Peer @angular/router@3.0.0-beta.1 wants @angular/common@^2.0.0-rc.4
npm ERR! peerinvalid Peer ng2-bootstrap@1.0.24 wants @angular/common@2.0.0-rc.4
我尝试过新的npm安装。我已尝试运行npm install npm -g
,我尝试在全局和appdata中清除node_modules
。我用Google搜索,几乎找不到任何东西。也许是因为我的谷歌搜索很糟糕。或者也许是因为实际上找不到任何东西。我不确定。但是我很慌张,感觉就像是时候制作我的第一篇Stackoverflow帖子了,虽然它绝对让人感觉更像是一种恳求。
答案 0 :(得分:1)
它清楚地告诉你什么是错的。你正在安装一些angular2与最新版本和一些以前的版本,这就是为什么你会得到这个错误。尝试安装所有最新版本或以前的版本。
答案 1 :(得分:0)
安装最新版本nodejs(nodejs.org)。再试一次。 npm install