I wanna use react-native-video in my project, but when I start compiling, I get this error: "Could not find media-1.0.0.jar (androidx.media:media:1.0.0)". My build.gradle file:
buildscript {
ext {
buildToolsVersion = "30.0.1"
minSdkVersion = 16
compileSdkVersion = 28
targetSdkVersion = 28
}
repositories {
google()
jcenter()
}
dependencies {
classpath('com.android.tools.build:gradle:3.6.2')
classpath 'com.google.gms:google-services:4.2.0'
classpath 'com.android.tools.build:gradle:3.4.1'
}
}
allprojects {
repositories {
mavenLocal()
maven {
url("$rootDir/../node_modules/react-native/android")
}
maven {
url("$rootDir/../node_modules/jsc-android/dist")
}
google()
jcenter()
maven { url 'https://jitpack.io' }
}
}
How can I fix it? "implementation 'androidx.media:media:1.0.0'" doesn't help.
add implementation "androidx.media:media:1.2.1" into your app\build.gradle file in dependencies. Mine solved by that I hope it work out for you too.
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