Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

cannot uninstall Cordova plugin

In my Ionic app, I just uninstalled a Cordova plugin this way :

$ cordova plugin remove phonegap-facebook-plugin

Uninstalling phonegap-facebook-plugin from android

but when I list the plugins it still appears as installed :

$ cordova plugins
cordova-plugin-googleplayservices 19.0.3 "Google Play Services for Android"
cordova-plugin-googleplus 4.0.3 "Google+"
cordova-plugin-whitelist 1.1.1-dev "Whitelist"
ionic-plugin-keyboard 1.0.7 "Keyboard"
phonegap-facebook-plugin 0.12.0 "Facebook Connect"

Can help me figure this out ?

Thanks

like image 704
Louis Avatar asked Oct 22 '15 09:10

Louis


People also ask

How do I remove Cordova platform?

'cordova platform update /path/to/android/platform --save' => In addition to updating the android platform to version in the folder, update config. xml entry. 'cordova platform remove android --save' => Removes the android platform from the project and deletes its entry from config. xml.


3 Answers

Please delete phonegap-facebook-plugin from your plugin folder manually.

like image 102
Muhsin Keloth Avatar answered Oct 09 '22 05:10

Muhsin Keloth


the problem is you have to use the --save flag when you run the cordova plugin rm command. cordova plugin remove phonegap-facebook-plugin --save

This --save flag tells the compiler to also remove it from config.xml , where all the plugins are listed. When you don't pass the --save flag, the plugin entry remains in the config.xml and thus when you run: "cordova plugins ls", your plugin is still there..

This should be highlighted more clearly in the official cordova docs..

like image 24
OneXer Avatar answered Oct 09 '22 06:10

OneXer


You can remove any cordova plugin forcefully by using below command,

cordova plugin remove phonegap-facebook-plugin--force

then try to remove all platforms using below command,

cordova platform remove <platform_name>

then try to add platforms again using below command,

cordova platform add <platform_name>

Finally prepare project using below command,

cordova prepare
like image 29
Nimesh khatri Avatar answered Oct 09 '22 06:10

Nimesh khatri