我试图在官方文档的帮助下安装ionic插件键盘。但是在第二个命令上,即 npm install --save @ionic-native/keyboard
我得到以下错误:
+-- UNMET PEER DEPENDENCY @ionic-native/core@3.12.1
`-- @ionic-native/keyboard@4.3.2
这是我的package.json
"dependencies": {
"@angular/common": "4.1.3",
"@angular/compiler": "4.1.3",
"@angular/compiler-cli": "4.1.3",
"@angular/core": "4.1.3",
"@angular/forms": "4.1.3",
"@angular/http": "4.1.3",
"@angular/platform-browser": "4.1.3",
"@angular/platform-browser-dynamic": "4.1.3",
"@ionic-native/core": "^3.12.1",
"@ionic-native/keyboard": "^4.3.2",
"@ionic-native/splash-screen": "^3.12.1",
"@ionic-native/sqlite": "^4.0.1",
"@ionic-native/status-bar": "^3.12.1",
"@ionic/storage": "2.0.1",
"cordova-android": "^6.2.3",
"cordova-plugin-console": "^1.0.5",
"cordova-plugin-device": "^1.1.4",
"cordova-plugin-splashscreen": "^4.0.3",
"cordova-plugin-statusbar": "^2.2.2",
"cordova-plugin-whitelist": "^1.3.1",
"cordova-sqlite-storage": "^2.0.4",
"cordova-windows": "^5.0.0",
"ionic-angular": "3.5.3",
"ionic-native": "^2.9.0",
"ionic-plugin-keyboard": "^2.2.1",
"ionicons": "3.0.0",
"rxjs": "5.4.0",
"sw-toolbox": "3.6.0",
"zone.js": "0.8.12"
}
我尝试将@ionic-native/core
更改为 4.3.2。但是没有运气。请帮忙。
似乎它正在尝试找到确切的"@ionic-native/core": "3.12.1"
版本,但您有^3.12.1
.
您可以尝试将^3.12.1
更改为 3.12.1
,删除node_modules/
目录,然后再次运行npm install
以查看是否可以解决您的问题。