From 76b2dfa9aac230e7c0459511a018f4a6891b5720 Mon Sep 17 00:00:00 2001 From: gasolin Date: Tue, 28 May 2024 11:24:03 +0800 Subject: [PATCH] Fix Android Gradle Plugin error >= 8.x.x --- android/build.gradle | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/android/build.gradle b/android/build.gradle index 95dbd54..ade2dc9 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -27,7 +27,10 @@ def getExtOrIntegerDefault(name) { } android { - // namespace 'com.rivereactnative' + // Conditional for compatibility with AGP <4.2. + if (project.android.hasProperty("namespace")) { + namespace = "com.rivereactnative" + } compileSdkVersion getExtOrIntegerDefault('compileSdkVersion') buildToolsVersion getExtOrDefault('buildToolsVersion') defaultConfig {