Hi, what’s the best way to update ionic-native? I’m looking at this post and it seems I need to a) manually update all cordova plugins b) manually also update each ionic-native npm package associated to the cordova plugins in addition to installing @core - is that correct?
Yup, you’ve got it.
One minor note though, is that ionic-native updates independently of the underlying cordova plugin. So you may not need to do step A when you do step B. It’s generally a good idea to check to make sure your cordova plugins are up to date though, naturally.
Thanks - that was a rather laborious plugin update process (15 * 2 updates, one for npm one for cordova) but everything is sorted out and I seem to have a clean env. with old versions out of the way. You’re right - most of the cordova plugins retained their versions, except for one or two, while all the native wrapper npm counterparts bumped up to
Can you please share the commands that you used to
A) Upgrade the cordova-plugins
B) @ionic-native/XXXX packages?
Did you just do?
npm install --save @ionic-native/XXXX@latest
— For ionic-native —
- I saw the latest ionic-native version here
- I modified my package.json
@ionic-nativeentries to that version
- I did
rm -fr ./node_modules && npm install
— For cordova plugins —
Yes, I first did it manually, but then I found cordova-check-plugins which makes it much simpler
I just installed this, and it looks awesome! What a great tool. Thanks for posting.
ionic doctor check does the job!
How do you use doctor to upgrade? (I am on a v1 project)
I did a check and it said:
ionic doctor check ✔ Detecting issues: 16 / 16 complete - done! [OK] Detected 0 issues. Aww yeah! 💪
But then I did ls and it said many things:
ionic doctor ls automatic-updates-off npm-installed-locally ionic-installed-locally git-not-used git-config-invalid ionic-angular-update-available ionic-angular-major-update-available app-scripts-update-available app-scripts-major-update-available ionic-native-old-version-installed ionic-native-update-available ionic-native-major-update-available unsaved-cordova-platforms cordova-platforms-committed default-cordova-bundle-id-used viewport-fit-not-set
What next? How do you fix? The online docs don’t say much
It does exactly what it says on the box:
List all issue identifiers
If it doesn’t detect any issues for your app it can’t help you.
Ah so ls is not telling me I have issues. It’s just listing the areas doctor investigates. That helps - ‘ listing issue identifiers’ confused me. I though it means ‘I have the following list of issues’