gpt4 book ai didi

android - @angular/core@2.0.0-rc.1 包不满足其 sibling 的 peerDependencies 要求!

转载 作者:行者123 更新时间:2023-11-30 01:11:42 24 4
gpt4 key购买 nike

所以我正在设置这个开源 app .

当我运行 tns run android --emulator 它给了我这个错误:

Unable to install dependencies. Make sure your package.json is valid and all dependencies are correct. Error is: The package @angular/core@2.0.0-rc.1 does not satisfy its siblings' peerDependencies requirements!
Analytics statuses:
{ TrackFeatureUsage: 1, TrackExceptions: 1 }
Trying to track exception with message 'Unable to install dependencies. Make sure your package.json is valid and all dependencies are correct. Error is: The package @angular/core@2.0.0-rc.1 does not satisfy its siblings' peerDependencies requirements!'.

但是如果我检查日志文件,对等依赖项是:

  code: 'EPEERINVALID',
packageName: '@angular/core',
packageVersion: '2.0.0-rc.1',
peersDepending:
{ '@angular/common@2.0.0-rc.1': '2.0.0-rc.1',
'@angular/compiler@2.0.0-rc.1': '2.0.0-rc.1',
'@angular/http@2.0.0-rc.4': '^2.0.0-rc.4',
'@angular/platform-browser@2.0.0-rc.1': '2.0.0-rc.1',
'@angular/platform-browser-dynamic@2.0.0-rc.1': '2.0.0-rc.1',
'@angular/platform-server@2.0.0-rc.1': '2.0.0-rc.1',
'@angular/router-deprecated@2.0.0-rc.2': '^2.0.0-rc' } }

我的 package.json 文件:

  1 {
2 "description": "NativeScript Application",
3 "license": "SEE LICENSE IN <your-license-filename>",
4 "readme": "NativeScript Application",
5 "repository": "<fill-your-repository-here>",
6 "nativescript": {
7 "id": "org.nativescript.mobile",
8 "tns-ios": {
9 "version": "2.0.1"
10 },
11 "tns-android": {
12 "version": "2.0.0"
13 }
14 },
15 "dependencies": {
16 "@angular/core": "2.0.0-rc.1",
17
18 "@angular/common": "2.0.0-rc.1",
19 "@angular/compiler": "2.0.0-rc.1",
20 "@angular/http": "^2.0.0-rc.4",
21 "@angular/platform-browser": "2.0.0-rc.1",
22 "@angular/platform-browser-dynamic": "2.0.0-rc.1",
23 "@angular/platform-server": "2.0.0-rc.1",
24 "@angular/router-deprecated": "^2.0.0-rc",
25
26 "nativescript-angular": "0.1.1",
27 "nativescript-pulltorefresh": "^1.1.4",
28 "nativescript-socket.io": "^0.1.6",
29 "tns-core-modules": "^2.0.0"
30 },
31 "devDependencies": {
32 "babel-traverse": "6.9.0",
33 "babel-types": "6.9.1",
34 "babylon": "6.8.0",
35 "filewalker": "0.1.2",
36 "lazy": "1.0.11",
37 "nativescript-dev-typescript": "^0.3.2",
38 "typescript": "^1.8.10"
39 }
40 }

有什么办法可以解决这个问题吗?我已经为这个问题奋斗了几个小时,希望得到一些帮助。

现在只是填写文本,所以堆栈溢出让我发布这个问题。

最佳答案

通过更新 package.json 文件解决。

从@angular 版本中删除了 ^ 字符。

关于android - @angular/core@2.0.0-rc.1 包不满足其 sibling 的 peerDependencies 要求!,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38375027/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com