def getExtOrDefault(name, defaultValue) {
    return rootProject.ext.has(name) ? rootProject.ext.get(name) : defaultValue
}

buildscript {
    if (project == rootProject) {
        repositories {
            google()
            jcenter()
        }
        dependencies {
            classpath 'com.android.tools.build:gradle:4.2.1'
        }
    }
}

apply plugin: 'com.android.library'

android {
    compileSdkVersion getExtOrDefault('compileSdkVersion', 29)

    defaultConfig {
        minSdkVersion getExtOrDefault('minSdkVersion', 21)
        targetSdkVersion getExtOrDefault('targetSdkVersion', 29)
    }
    lintOptions{
        abortOnError false
    }
}

repositories {
    google()
    maven {
        // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
        url "../node_modules/react-native/android"
    }
    jcenter()
}

dependencies {
    implementation 'com.facebook.react:react-native:+'
    implementation 'io.card:android-sdk:5.5.1'
    implementation 'ru.yoomoney.sdk.kassa.payments:yookassa-android-sdk:6.7.0'
}
