Search code examples
androidcordovaionic-framework

unable to install latest android version with ionic platform add android


I want to install latest android version but whenever I run ionic platform add android the cli install android version 6.

However if i do ionic platform add [email protected] it install version 6.1.10 but i want to install the latest version with ionic platform add android command.

How can i install android version > 6 with this command.

My config.xml conf is:

<preference name="android-minSdkVersion" value="16" />
<preference name="android-targetSdkVersion" value="25" />

Solution

  • You can install the latest version by running

      cordova platform add [email protected]
    

    From their site

    This release will have to be explicitly added until the upcoming cordova@7 release, where it will be pinned as the default android platform.