【问题标题】:While updating compileSdkVersion & targetSdkVersion to 26 - duplicate value for resource 'attr/fontFamily' with config在将 compileSdkVersion 和 targetSdkVersion 更新为 26 时 - 使用配置的资源“attr/fontFamily”的重复值
【发布时间】:2018-08-06 19:16:14
【问题描述】:

我正在将我的应用程序编译和目标 SDK 版本从 23 更新到 26 (Android 8.0)。但更新后出现如下错误:

错误:资源“attr/fontFamily”的值与配置“重复”。

现在在 gradle 中有以下支持库:

implementation 'com.android.support:support-v4:26.1.0'
implementation 'com.android.support:cardview-v7:26.1.0'
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support:design:26.1.0'

请不要建议将 targetSdkVersion 降级到 25。也不要建议这个问题:Duplicate value for resource 'attr/font' with config "

【问题讨论】:

    标签: android android-studio android-sdk-tools android-gradle-3.0 android-buildconfig


    【解决方案1】:

    基本上,问题在于应用程序中使用了较旧的依赖项来使用 RobotoTextView。我已经能够通过更新这个库来解决这个问题。

    来自:

    implementation 'com.github.johnkil.android-robototextview:robototextview:2.5.0'
    

    到:

    implementation 'com.github.johnkil.android-robototextview:robototextview:4.0.0'
    

    【讨论】:

      猜你喜欢
      • 2019-08-10
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多