apply plugin: "com.android.library"

def extGetOrDefault(prop, fallback) {
    rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
}

android {   
    compileSdkVersion extGetOrDefault('compileSdkVersion', 30)
    buildToolsVersion extGetOrDefault('buildToolsVersion', "30.0.2")

    defaultConfig {
        minSdkVersion extGetOrDefault('minSdkVersion', 16)
        targetSdkVersion extGetOrDefault('targetSdkVersion', 30)
        versionCode 1
        versionName "1.0.0"
    }
}

allprojects {
    repositories {
        mavenLocal()
        jcenter()
        maven {
            // For developing the library outside the context of the example app, expect `react-native`
            // to be installed at `./node_modules`.
            url "$projectDir/../node_modules/react-native/android"
        }
    }
}

dependencies {
    implementation "com.facebook.react:react-native:+"
}
