Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not find media-1.0.0.jar (androidx.media:media:1.0.0)

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.

like image 300
Shadowman Avatar asked Dec 14 '25 14:12

Shadowman


1 Answers

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.

like image 156
mohammad hakimi Avatar answered Dec 16 '25 09:12

mohammad hakimi



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!