Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change api level 29 to 30 in expo react native App

This Message was appear when i upload my app bundle to play store

Your app currently targets API level 29 and must target at least API level 30 to ensure it is built on the latest APIs optimized for security and performance. Change your app's target API level to at least 30.

like image 606
Muditha Avatar asked Aug 25 '21 16:08

Muditha


2 Answers

If you have a managed workflow expo app. To make expo target new Api level 30, you need to upgrade your app to Expo SDK 41 or higher. Do the following ;

  1. Upgrade your expo cli to 41 or higher - npm i -g expo-cli [email protected]
  2. Run expo upgrade on your project
  3. Create a new build of your app for Google Paystore - expo build:android

This will now target api 30

like image 170
AyoDavid Avatar answered Oct 04 '22 02:10

AyoDavid


Open build.gradle under android/app/

find the android { } block

Change the following version to the below:

compileSdkVersion 27
buildToolsVersion "27.0.3"
minSdkVersion 16
targetSdkVersion 27

In case your current android/app/build.gradle has lines which look like :

compileSdkVersion rootProject.ext.compileSdkVersion
buildToolsVersion rootProject.ext.buildToolsVersion

You will have to edit the android/build.gradle to include :

buildscript {
    ext {
        buildToolsVersion = "28.0.3"
        minSdkVersion = 21
        compileSdkVersion = 28
        targetSdkVersion = 28
        supportLibVersion = "28.0.0"
    }
    ...
}
like image 45
Syafiqur__ Avatar answered Oct 04 '22 02:10

Syafiqur__