'Cordova could not load API for android project

I've been trying to run android project using Visual Studio 2017 and Cordova. When i try to run the app on the android emulator from command prompt it doesnt work and said that it could not load API for the android project from API.js. Is there any thing I can do to fix the problem?

Attached is the screenshot from the command prompt with the error mentioned.

I have tried to use the command cordova emulate android but to no avail.



Solution 1:[1]

I would you advise you to avoid Visual Studio for Cordova development. As far as I know they discontinued the support for Cordova and you might be using a very old version.

You can manage your Cordova project with the official command line interface and edit your code with the editor of your chossing like Visual Studio or Visual Studio Code.

Make sure to use the latest version of the documentation and prepare your environment for the platforms like Android

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1