2016-10-24 5 views
0

npm에서 angular2 재질을 설치했습니다. 그러나, 이제이 @angular/[email protected]^2.0.0에 따라, 나는 다른 패키지를 설치할하지만 오류Angular2 @ Angular/Material unmet dependency

npm ERR! peerinvalid The package @angular/[email protected] does not satisfy its siblings' peerDependencies requirements! 
npm ERR! peerinvalid Peer @angular/[email protected] wants @angular/[email protected] 
npm ERR! peerinvalid Peer @angular/[email protected] wants @angular/[email protected]^2.0.0 
npm ERR! peerinvalid Peer @angular/[email protected] wants @angular/[email protected] 
npm ERR! peerinvalid Peer @angular/[email protected] wants @angular/[email protected] 
npm ERR! peerinvalid Peer @angular/[email protected] wants @angular/[email protected] 
npm ERR! peerinvalid Peer @angular/[email protected] wants @angular/[email protected] 

내가 @angular/material의 마지막 버전을 사용하고 있습니다. 충돌을 수정하고 이러한 패키지를 사용하려면 어떻게해야합니까?

package.json :

{ 
    "name": "materialdesign", 
    "version": "0.0.0", 
    "license": "MIT", 
    "angular-cli": {}, 
    "scripts": { 
    "start": "ng serve", 
    "lint": "tslint \"src/**/*.ts\"", 
    "test": "ng test", 
    "pree2e": "webdriver-manager update", 
    "e2e": "protractor" 
    }, 
    "private": true, 
    "dependencies": { 
    "@angular/common": "~2.0.0", 
    "@angular/compiler": "~2.0.0", 
    "@angular/core": "~2.0.0", 
    "@angular/forms": "~2.0.0", 
    "@angular/http": "~2.0.0", 
    "@angular/material": "^2.0.0-alpha.9-3", 
    "@angular/platform-browser": "~2.0.0", 
    "@angular/platform-browser-dynamic": "~2.0.0", 
    "@angular/router": "~3.0.0", 
    "bootstrap": "^3.3.7", 
    "core-js": "^2.4.1", 
    "rxjs": "5.0.0-beta.12", 
    "ts-helpers": "^1.1.1", 
    "watchman": "^0.1.8", 
    "zone.js": "^0.6.23" 
    }, 
    "devDependencies": { 
    "@types/jasmine": "^2.2.30", 
    "@types/node": "^6.0.42", 
    "angular-cli": "1.0.0-beta.17", 
    "codelyzer": "~0.0.26", 
    "jasmine-core": "2.4.1", 
    "jasmine-spec-reporter": "2.5.0", 
    "karma": "1.2.0", 
    "karma-chrome-launcher": "^2.0.0", 
    "karma-cli": "^1.0.1", 
    "karma-jasmine": "^1.0.2", 
    "karma-remap-istanbul": "^0.2.1", 
    "protractor": "4.0.9", 
    "ts-node": "1.2.1", 
    "tslint": "3.13.0", 
    "typescript": "2.0.2" 
    } 
} 
+0

/일반 버전? packages.json 파일에서 확인할 수 있습니다. – Sefa

+0

package.json으로 질문을 업데이트했습니다. –

+0

'npm install --save @ angular/common @ 2.0.2' 버전을 포함하여 설치를 시도하십시오. – Sefa

답변

1

종속성 확인 문제 같은데; 나는 다음 단계로 고정 비슷한 문제가 있었다 :

  1. 으로 업그레이드를 latest NodeJS version
  2. npm --version하고 있는지 확인 그것의 3.10.x
  3. npm install
  4. npm rebuild
당신의 @는 각 무엇
+0

위와 같은 오류가 발생합니다. –

+0

@ BünyaminSarıgül 나는 내 대답에 약간을 더했다. 만약 당신이 여전히 문제에 직면하면, 말해 : 당신이'npm - 버전'을 할 때 당신은 무엇을 보나요? 'node --version'은 어떨까요? – BeetleJuice

+0

npm 2.15.9, 노드 v4.6.1 –