From e2bc1a65f4fa56b9fb142db90805f53fa681cef4 Mon Sep 17 00:00:00 2001 From: Vincent Ritter Date: Sat, 5 Nov 2022 18:09:45 +0100 Subject: [PATCH] Add RN fix for build errors. https://github.com/facebook/react-native/issues/35210 --- android/app/src/main/AndroidManifest.xml | 8 +++++--- android/build.gradle | 15 +++++++++++++++ 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index 7585493b..febc868f 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -13,7 +13,8 @@ android:icon="@mipmap/ic_launcher" android:roundIcon="@mipmap/ic_launcher" android:allowBackup="false" - android:theme="@style/AppTheme"> + android:theme="@style/AppTheme" + android:exported="true"> @@ -21,7 +22,7 @@ - + @@ -40,6 +41,7 @@ @@ -51,7 +53,7 @@ android:label="@string/app_name" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|uiMode" android:launchMode="singleTask" - android:windowSoftInputMode="adjustResize" android:theme="@style/AppTheme"> + android:windowSoftInputMode="adjustResize" android:theme="@style/AppTheme" android:exported="true"> diff --git a/android/build.gradle b/android/build.gradle index d3dcf633..c6efe87d 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -24,6 +24,21 @@ buildscript { allprojects { repositories { + exclusiveContent { + // We get React Native's Android binaries exclusively through npm, + // from a local Maven repo inside node_modules/react-native/. + // (The use of exclusiveContent prevents looking elsewhere like Maven Central + // and potentially getting a wrong version.) + filter { + includeGroup "com.facebook.react" + } + forRepository { + maven { + url "$rootDir/../node_modules/react-native/android" + } + } + } + mavenCentral() mavenLocal() maven {