I installed cordova and create a new project.
But when I use this command to add android platform:
cordova platform add android
When I tried to remove the android platform from my project directory using this command: cordova platform rm android, it failed.But I managed to do it using the following steps:
cordova-android folder manually from node_modules.cordova-android dependency from package.json.cordova platform add android --nofetch.After these the Platform was added successfully.