簡體   English   中英

添加實現 'com.google.firebase:firebase-analytics:17.2.2' 使實現 'com.android.support:appcompat-v7:28.0.0' 用紅色下划線

[英]adding implementation 'com.google.firebase:firebase-analytics:17.2.2' make implementation 'com.android.support:appcompat-v7:28.0.0' underlined in red

After creating an application and a project on Firebase and downloading google-service.json and placing it in the app repository everything is fine until I try to add any firebase service SDK and after syncing I get the following line:

實現 'com.android.support:appcompat-v7:28.0.0' 帶有紅色下划線和以下錯誤

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 <application> element at AndroidManifest.xml: 5: 5-19: 19 to override.

您必須將您的項目遷移到 androidX,請按照下列步驟操作:

Refactor -> Refactor this -> Migrate To AndroidX -> (將彈出一條消息詢問您是否要備份項目,由您決定)-> Do Refactor -> 項目將同步你對 go 很好。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM