FAQ & Troubleshooting (React Native)
Android
Picture in Picture(PIP) cannot be closed normally when killing the application in Android 11
Out of JVM Memory
Gradle build daemon has been stopped: JVM garbage collector thrashing and after running out of JVM memory. Add the following configuration to the file:
gradle.properties
.
Gradle plugin version is larger than 4.1.x
If your Gradle plugin version is larger than
com.android.tools.build:gradle:4.1.x
. Please set the
compileSdkVersion = 31
and
targetSdkVersion = 31
. And add the following configuration to the file:
src/main/AndroidManifest.xml
.
Use JDK11 and Gradle 7.x.
If you want to use JDK11 and Gradle 7.x. Please do:
-
JAVA_HOME = JDK11 (system env)
-
classpath("com.android.tools.build:gradle:7.x.x") (build.gradle)
-
distributionUrl=https://services.gradle.org/distributions/gradle-7.x-all.zip (gradle-wrapper.properties)
-
And change the following configuration in the file:
app/firework.gradle
.
minCompileSdk = 31
-
If you met the issue like below:
Please do:
Maybe your
compileSdkVersion = 30
and
targetSdkVersion = 30
, your Gradle is below 6.9-all and the Gradle plugin is
com.android.tools.build:gradle:4.1.x
.
Okhttp version issue
If you met the issue like below:
Maybe your okhttp version is 3.x.x . Please do:
Solution: force the version to your
app/firework.gradle
file, like below: