buildscript {
  repositories {
      google()
      mavenCentral()
  }

  dependencies {
    classpath 'com.android.tools.build:gradle:3.5.1'
  }
}

apply plugin: 'com.android.library'

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

android {
    compileSdkVersion safeExtGet('compileSdkVersion', 28)
    buildToolsVersion "23.0.1"

    defaultConfig {
        minSdkVersion safeExtGet('minSdkVersion', 16)
        targetSdkVersion safeExtGet('targetSdkVersion', 28)
        versionCode 1
        versionName "1.0"
        ndk {
            abiFilters "armeabi-v7a", "x86"
        }
    }

    compileOptions {
        sourceCompatibility = 1.8
        targetCompatibility = 1.8
    }
}

repositories {
  google()
  mavenCentral()
}

dependencies {
    implementation "com.facebook.react:react-native:${safeExtGet('reactNativeVersion', '+')}"
    // https://mvnrepository.com/artifact/com.github.andriydruk/rx2dnssd
    api group: 'com.github.andriydruk', name: 'rx2dnssd', version: '0.9.16'
    // https://mvnrepository.com/artifact/org.apache.commons/commons-lang3
    api group: 'org.apache.commons', name: 'commons-lang3', version: '3.11'
}
