@richardshergold wrote:
In my app I need to use the network information plug-in so to add it I ran the command:
ionic plugin add cordova-plugin-network-information
In my Ionic 1 apps I always used ionic plugin add to add my plug-ins as the plug-in is then automatically added to the package.json file (which I assumed was good).
Anyway, after adding the plug-in (and without adding any code to actually use it) I built the app and tested it on a device. The app crashed on loading (no errors in the log - just crashed on startup). I removed the plug-in and added it again and re-tested. Same thing happened.
Then I tried removing the plug-in and adding it back again but this time using:
cordova plugin add cordova-plugin-network-information
This time when I built the app, it worked. What's the difference between using the ionic plugin add and the cordova plugin add commands? I thought the only difference was the entry in package.json but presumably there are other differences?
Posts: 1
Participants: 1