1
votes

When do we need to save a plugin in config.xml?

Normally we use cordova plugin add <plugin-name> to add and save the plugin into our package.json

The Cordova documentation says that those plugins into config.xml will be restored during a prepare. What does this mean? Can we just set plugins in one place? Is there any problem having plugins only in package.json? Also I checked previous answers but it's still confusing me.

Thank you so much for your time : ) Note: I'm using Cordova 9.0.0

1

1 Answers

1
votes

Cordova 9.0.0 no longer uses config.xml as the source of plugin (or platform) data/versions.

https://github.com/apache/cordova-docs/issues/1004

Now, everything is just in one place : ) in package.json so we can remove platforms and plugins from config.xml