Plugin installation problem


#1

Hello, I can not install plugin anymore, when I had to do it, I have the following message:

C:\Users…>npm install --save @ionic-native/camera
Drugstore@0.0.0 C:\Users\fyonou\IONIC\Drugstore
±- @ionic-native/camera@4.3.2
`-- UNMET PEER DEPENDENCY @ionic-native/core@3.12.1

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.2: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“win32”,“arch”:“x64”})
npm WARN @ionic-native/camera@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/crop@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/deeplinks@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/file@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/file-path@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/file-transfer@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/image-picker@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/sms@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/social-sharing@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.

Please help!!!


#2

What does your package.json look like?


#3

{
“name”: “xxxxxxxxxx”,
“version”: “0.0.0”,
“author”: “xxxxxxxxxxx”,
“homepage”: “xxxxxxxxxxxxxxxxxx”,
“private”: true,
“scripts”: {
“clean”: “ionic-app-scripts clean”,
“build”: “ionic-app-scripts build”,
“lint”: “ionic-app-scripts lint”,
“ionic:build”: “ionic-app-scripts build”,
“ionic:serve”: “ionic-app-scripts serve”
},
“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/camera": “^4.3.2”,
"@ionic-native/core": “3.12.1”,
"@ionic-native/crop": “^4.3.2”,
"@ionic-native/deeplinks": “^4.3.2”,
"@ionic-native/diagnostic": “^4.2.1”,
"@ionic-native/file": “^4.3.2”,
"@ionic-native/file-path": “^4.3.2”,
"@ionic-native/file-transfer": “^4.3.2”,
"@ionic-native/geolocation": “^4.2.0”,
"@ionic-native/image-picker": “^4.3.2”,
"@ionic-native/local-notifications": “^4.2.1”,
"@ionic-native/location-accuracy": “^4.2.1”,
"@ionic-native/native-geocoder": “^4.2.1”,
"@ionic-native/native-storage": “^4.2.0”,
"@ionic-native/network": “^4.2.1”,
"@ionic-native/sms": “^4.3.2”,
"@ionic-native/social-sharing": “^4.3.2”,
"@ionic-native/splash-screen": “3.12.1”,
"@ionic-native/status-bar": “3.12.1”,
"@ionic-native/transfer": “^3.14.0”,
"@ionic/storage": “2.0.1”,
"@ngx-translate/core": “^8.0.0”,
"@ngx-translate/http-loader": “^0.1.0”,
“cordova-browser”: “^5.0.0”,
“cordova-plugin-console”: “1.0.5”,
“cordova-plugin-crop”: “^0.4.0”,
“cordova-plugin-device”: “1.1.4”,
“cordova-plugin-geolocation”: “~2.4.3”,
“cordova-plugin-image-picker”: “^1.1.3”,
“cordova-plugin-splashscreen”: “~4.0.1”,
“cordova-plugin-statusbar”: “2.2.2”,
“cordova-plugin-telerik-imagepicker”: “^2.1.8”,
“cordova-plugin-whitelist”: “1.3.1”,
“cordova-plugin-x-socialsharing”: “^5.2.1”,
“cordova-sms-plugin”: “^0.1.11”,
“es6-promise-plugin”: “^4.1.0”,
“ionic-angular”: “3.6.0”,
“ionic-plugin-deeplinks”: “^1.0.15”,
“ionic-plugin-keyboard”: “~2.2.1”,
“ionicons”: “3.0.0”,
“rxjs”: “5.4.0”,
“sw-toolbox”: “3.6.0”,
“zone.js”: “0.8.12”
},
“devDependencies”: {
"@ionic/app-scripts": “^3.0.0”,
"@types/googlemaps": “^3.26.20”,
“typescript”: “2.3.4”
},
“cordovaPlugins”: [
“cordova-plugin-console”,
“cordova-plugin-statusbar”,
“cordova-plugin-whitelist”,
“cordova-plugin-device”,
“cordova-plugin-splashscreen”,
“ionic-plugin-keyboard”
],
“cordovaPlatforms”: [],
“description”: “xxxxxxxxxxx: An Ionic project”,
“cordova”: {
“plugins”: {
“ionic-plugin-keyboard”: {},
“cordova-plugin-whitelist”: {},
“cordova-plugin-console”: {},
“cordova-plugin-statusbar”: {},
“cordova-plugin-device”: {},
“cordova-plugin-splashscreen”: {},
“cordova-plugin-geolocation”: {},
“cordova-plugin-image-picker”: {},
“cordova-plugin-crop”: {},
“ionic-plugin-deeplinks”: {
“URL_SCHEME”: “demoapp”,
“DEEPLINK_SCHEME”: “https”,
“DEEPLINK_HOST”: “demoapp.com”,
“ANDROID_PATH_PREFIX”: “/”,
“ANDROID_2_PATH_PREFIX”: “/”,
“ANDROID_3_PATH_PREFIX”: “/”,
“ANDROID_4_PATH_PREFIX”: “/”,
“ANDROID_5_PATH_PREFIX”: “/”,
“DEEPLINK_2_SCHEME”: " ",
“DEEPLINK_2_HOST”: " ",
“DEEPLINK_3_SCHEME”: " ",
“DEEPLINK_3_HOST”: " ",
“DEEPLINK_4_SCHEME”: " ",
“DEEPLINK_4_HOST”: " ",
“DEEPLINK_5_SCHEME”: " ",
“DEEPLINK_5_HOST”: " "
},
“cordova-plugin-x-socialsharing”: {},
“cordova-sms-plugin”: {}
},
“platforms”: [
“browser”
]
}
}


#4

Alright. So first, just to clarify, you don’t have any errors here, it’s just letting you know that certain plugins are expecting certain versions of other plugins to be installed.

I’d go and update all of your @ionic-native plugins to be the same version, so update:
@ionic-native/core
@ionic-native/diagnostic
@ionic-native/geolocation
@ionic-native/local-notifications
@ionic-native/location-accuracy
@ionic-native/native-geocoder
@ionic-native/native-storage
@ionic-native/network
@ionic-native/splash-screen
@ionic-native/status-bar
and,
@ionic-native/transfer

You should be able to do:
npm i @ionic-native/core @ionic-native/diagnostic @ionic-native/geolocation @ionic-native/local-notifications @ionic-native/location-accuracy @ionic-native/native-geocoder @ionic-native/native-storage @ionic-native/network @ionic-native/splash-screen @ionic-native/status-bar @ionic-native/transfer --save

To update them in one fell swoop.


#5

Hello, thanks for the tip, I tried to update all my native plugins and here is the message that appears:

±- UNMET PEER DEPENDENCY @ionic-native/core@3.12.1
±- @ionic-native/diagnostic@4.3.3
±- @ionic-native/geolocation@4.3.3
±- @ionic-native/local-notifications@4.3.3
±- @ionic-native/location-accuracy@4.3.3
±- @ionic-native/native-geocoder@4.3.3
±- @ionic-native/native-storage@4.3.3
±- @ionic-native/network@4.3.3
±- @ionic-native/splash-screen@3.12.1
±- @ionic-native/status-bar@3.12.1
`-- @ionic-native/transfer@3.14.0

npm WARN @ionic-native/app-version@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/camera@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/crop@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/deeplinks@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/device@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/diagnostic@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/file@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/file-path@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/file-transfer@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/geolocation@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/image-picker@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/local-notifications@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/location-accuracy@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/native-geocoder@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/native-storage@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/network@4.3.3 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/sms@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/social-sharing@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.
npm WARN @ionic-native/unique-device-id@4.3.2 requires a peer of @ionic-native/core@^4.2.0 but none was installed.


#6

Hello, thanks for the tip, I tried to update all my native plugins and here is the message that appears:


#7

Hello,
keep a copy of package.json for fallback.

Update your ionic-native/core@3.12.1 to ionic-native/core@4.2.0

Best regards, anna-liebt