Android Failed to resolve: com.github.PhilJay:MPAndroidChart:v3.1.0

发布时间 2023-09-23 17:20:11作者: zhaogaojian

2022.3.1版本
修改settings.gradle

dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        maven { url "https://jitpack.io" } // Add this repository
        jcenter() // or other repositories
        google()
        mavenCentral()

    }
}

增加一句话

maven { url "https://jitpack.io" } // Add this repository
jcenter() // or other repositories