android studio 编译 Android dependency has different version

找了一圈,终于在大佬的博客中找到了解决方法。

附链接:https://blog.csdn.net/u010725171/article/details/81232183

Android dependency has different version for the compile and runtime

在module的外层的build.gradle中添加

subprojects {
        project.configurations.all {
            resolutionStrategy.eachDependency { details ->
                if (details.requested.group == ‘com.android.support‘
                        && !details.requested.name.contains(‘multidex‘) ) {
                    details.useVersion ‘28.0.0‘ //这个版本号设置为你想要的版本
                }
            }
        }
    }

android studio 编译 Android dependency has different version

android studio 编译 Android dependency has different version

上一篇:asp.net core mvc 读取appsettings.config中文乱码问题


下一篇:JavaScript 键盘流畅移动div