英文:
Appcompat activity along with androidx gradle version issue in android studio
问题
Appcompat版本用于应用程序是v7,与gradle.properties集成使用androidx以进行firebase连接
请帮忙
英文:

Appcompat version used in app is v7, androidx is used for integration with gradle.properties for firebase connection
Please help
答案1
得分: 0
你正在使用错误的build.gradle文件
你需要将顶层文件中的implementation部分移动到app/build.gradle文件中的dependencies块中(而不是buildscript块中的dependencies):
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
android {
//...
}
dependencies {
//...
implementation 'androidx.xxxxx'
}
英文:
You are using the wrong build.gradle file
You have to move the implementation from the top-level file to the app/build.gradle file in the dependencies block (not the dependencies in the buildscript block)::
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
android {
//...
}
dependencies {
//...
implementation 'androidx.xxxxx'
}
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。


评论