I am trying to implement in a Braintree application and the following problem arises. When I try to add the following dependency.
implementation 'com.braintreepayments.api:drop-in:3.3.0'
Skip the following Error:
Error: Program type already present: android.support.design.widget.CoordinatorLayout $ Behavior
Investigate and I found that to correct it, add:
allprojects {
repositories {
google()
jcenter()
maven {
url "https://maven.google.com"
}
}
}
But it did not work.
Change the version to 27 and it does not work either, I would really appreciate a help with this problem.
android {
compileSdkVersion 28
defaultConfig {
applicationId "termo.com.pagosbraintree2"
minSdkVersion 16
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(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
implementation 'com.squareup.retrofit2:converter-scalars:2.3.0'
implementation 'com.braintreepayments.api:drop-in:3.3.0'
implementation 'com.loopj.android:android-async-http:1.4.9'
}