0plus1
0plus1

Reputation: 4555

Cordova not recognizing plugins after updating them

I updated all the plugins I was using in cordova using the remove and add method.

cordova plugin rm org.apache.cordova.device
cordova plugin add org.apache.cordova.device
....

I then prepare and build

cordova prepare ios
cordova build ios

I test the app on the simulator and I get:

ERROR: Plugin 'Device' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml

Why is this happening? I was under the impression that the command line was going to update everything automatically, what am I missing?

Before the rm and add everything was working fine.

Thank you for your time.

Upvotes: 0

Views: 363

Answers (1)

0plus1
0plus1

Reputation: 4555

If anyone stumbles on this, I found the solution. After updating, adding or removing plugins, you should always do this:

cordova platform rm ios
cordova platform add ios

That will fix any issue.

Upvotes: 2

Related Questions