gpt4 book ai didi

android - V7 的 list 合并失败

转载 作者:行者123 更新时间:2023-11-29 18:28:31 26 4
gpt4 key购买 nike

我更新了一些东西,突然间发生了这种情况

ERROR: Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91 is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory). Suggestion: add 'tools:replace="android:appComponentFactory"' to element at AndroidManifest.xml:7:5-57:19 to override.

我已经查看了其他答案,但我无法真正弄清楚该做什么或要更改什么

apply plugin: 'com.android.application'

android {
compileSdkVersion 28
buildToolsVersion '28.0.3'
defaultConfig {
applicationId "com.example.khali.nutriplan"
minSdkVersion 22
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}

dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
testImplementation 'junit:junit:4.12'
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation 'com.android.volley:volley:1.1.0'
implementation 'org.jetbrains:annotations-java5:15.0'
implementation 'com.github.PhilJay:MPAndroidChart:v3.1.0-alpha'
implementation 'com.numetriclabz.numandroidcharts:numandroidcharts:1.0.18'
implementation 'com.xeoh.android:checkboxgroup:1.0.1'
implementation 'com.jjoe64:graphview:4.2.2'
implementation 'androidx.fragment:fragment:1.0.0'
}

什么是合适的库

最佳答案

你正在使用支持库和androix库,你做不到。

implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation 'androidx.fragment:fragment:1.0.0'

您必须迁移到 Androidx:

  • com.android.tools.build:gradle 升级到 v3.2.1 或更高版本。
  • compileSdkVersion升级到28或更高版本。
  • 更新您的应用以使用 Jetpack (AndroidX);按照 Migrating to AndroidX 中的说明进行操作.

关于android - V7 的 list 合并失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57587415/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com