Background: I am trying to setup RNUILib on a react-native project but it wont build. I followed the instructions from the official guide.
Environment: Android/Windows
Here's my dependencies:
@react-native-community/blur : 3.6.0
@react-native-community/datetimepicker : 3.5.2
@react-native-community/masked-view : 0.1.11
@react-native-community/netinfo : 6.0.1
@react-native-picker/picker : 1.16.7
@react-navigation/drawer : 6.1.4
@react-navigation/native : 6.0.2
react: 17.0.2
react-native: 0.65.1
react-native-gesture-handler : 1.10.3
react-native-reanimated : 2.3.0-alpha.2
react-native-safe-area-context : 3.3.0
react-native-screens : 3.6.0
react-native-ui-lib : 5.30.0
Error log from react-native run-android
command:
Execution failed for task ':app:checkDebugAarMetadata'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find com.eightbitlab:blurview:1.6.3.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/com/eightbitlab/blurview/1.6.3/blurview-1.6.3.pom
- https://repo.maven.apache.org/maven2/com/eightbitlab/blurview/1.6.3/blurview-1.6.3.pom
- file:/C:/Users/vfvic/.m2/repository/com/eightbitlab/blurview/1.6.3/blurview-1.6.3.pom
- file:/D:/_react-native/CBTracker2/node_modules/react-native/android/com/eightbitlab/blurview/1.6.3/blurview-1.6.3.pom
- file:/D:/_react-native/CBTracker2/node_modules/jsc-android/dist/com/eightbitlab/blurview/1.6.3/blurview-1.6.3.pom
- https://www.jitpack.io/com/eightbitlab/blurview/1.6.3/blurview-1.6.3.pom
Required by:
project :app > project :react-native-community_blur
As I have mentioned, I have performed all the steps in the Setup guide, including the linking of @react-native-community/blur
.
What you need to do is install a earlier version of Gradle for your project and then rebuild your app. Go to https://developer.android.com/studio/releases/gradle-plugin. Scroll down to the Update Gradle section. Here, you will see a table of Gradle version and Plugin version.
The Metro bundler runs on port 8081. If another process is already using that port, you can either terminate that process, or change the port that the bundler uses.
From the Command Palette, choose Nuclide Metro: Start to start Metro. The output in the Console panel indicates if Metro started or if it encountered any errors. The server runs on the default port 8081 . You can stop and restart the server at anytime.
On React Native 0.69, React 18 is enabled by default. However, if you have not migrated to the New Architecture, you will only be able to leverage the features that don't use concurrent rendering and concurrent features.
Nothing worked for me so I reinstalled lower version of RN, previously I was working with RN 0.65.1=> The only version of reanimated which is compatible with react native v65 is v2.3.0-alpha3. Try This
Spent hours in frustration that there is no stable release of react-native to proceed through Google requirements. Any ideas to make it work? As a temporary workaround it's enough to change just versions in the project level gradle file:
Today we’re releasing React Native version 0.65 with a new version of Hermes, improvements to accessibility, package upgrades, and more. What's new in Hermes 0.8? Hermes, Facebook’s open source JavaScript VM optimized for React Native, has been upgraded to version 0.8.1. Some of the stand-out features in this release are:
Apparently, this is due to com.eightbitlab:blurview being only available from jcenter which is required by react-native-community_blur.
I've added jcenter()
in my build.gradle file and it's now working fine.
allprojects {
repositories {
jcenter()
google()
mavenCentral()
mavenLocal()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url("$rootDir/../node_modules/react-native/android")
}
maven {
// Android JSC is installed from npm
url("$rootDir/../node_modules/jsc-android/dist")
}
maven { url 'https://www.jitpack.io' }
}
}
late but hope it will help someone, update android/build.gradle like below
allprojects {
repositories {
....rest
jcenter() {
content {
includeModule("com.eightbitlab", "blurview")
}
}
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With