apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.0"
defaultConfig {
applicationId "com.nata.volokhova.selfvocabuary"
minSdkVersion 16
targetSdkVersion 25
multiDexEnabled = true
versionCode 10
versionName "1.5.3"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'LICENSE.txt'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
testCompile 'junit:junit:4.12'
compile 'com.android.support:multidex:1.0.1'
//noinspection GradleCompatible
compile 'com.android.support:appcompat-v7:25.0.1'
compile 'com.android.support:design:25.0.1'
compile 'com.google.android.gms:play-services:10.0.0'
// Dependency for Google Sign-In
compile 'com.google.android.gms:play-services-auth:10.0.0'
// Dependency for AdMob
compile 'com.google.firebase:firebase-ads:9.6.1'
//Dependency for Real-time Database
compile 'com.google.firebase:firebase-database:9.6.1'
}
apply plugin: 'com.google.gms.google-services'
just put below lines in your project AndroidManifest.xml file if they're not in application tag
|
public class YourApplication extends Application {
@Override
protected void attachBaseContext(Context context) {
super.attachBaseContext(context);
MultiDex.install(this);
}
@Override
public void onCreate() {
super.onCreate();
Realm.init(this); //initialize other plugins
}
}
Add the above code it's working for me