1
0
Code Issues Pull Requests Packages Projects Releases Wiki Activity GitHub Gitee
2019-09-18 21:30:52 +08:00

37 lines
918 B
Groovy

def safeExtGet(prop, fallback) {
rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
}
apply plugin: 'com.android.library'
android {
compileSdkVersion safeExtGet('compileSdkVersion', 28)
buildToolsVersion safeExtGet('buildToolsVersion', '28.0.3')
defaultConfig {
minSdkVersion safeExtGet('minSdkVersion', 16)
targetSdkVersion safeExtGet('targetSdkVersion', 27)
versionCode 1
versionName "1.0"
consumerProguardFiles "proguard.pro"
}
sourceSets {
main {
// let gradle pack the shared library into apk
jniLibs.srcDirs = ['./lib']
}
}
}
repositories {
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
}
}
dependencies {
implementation 'com.facebook.react:react-native:+'
}