buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.3.3'
    }
}

apply plugin: 'com.android.library'

android {
    compileSdkVersion 26
    buildToolsVersion "25.0.3"

    defaultConfig {
        minSdkVersion 19
        targetSdkVersion 26
        versionCode 1
        versionName "1.0"
        ndk {
            abiFilters "armeabi-v7a", "x86"
        }
    }
    lintOptions {
        abortOnError false
    }
}

repositories {
    mavenCentral()
}
dependencies {
    /**
     * Using okhttp is better because it fixes a possible outofmemory exception.
     * However the okhttp library can have a funky version resolution and cause compilation errors with RN
     * There is a PR to fix that
     * https://github.com/facebook/react-native/pull/11835
     * Until that is merged and RN is upgraded, you need to add this line to your android/app/build.gradle, inside 'android' block:
     * configurations.all { resolutionStrategy.force 'com.squareup.okhttp3:okhttp:3.4.1' }
    */
    compile 'com.facebook.react:react-native:+'
    compile 'net.gotev:uploadservice-okhttp:3.4.1'
}
