|
@@ -2,6 +2,21 @@ def getExtOrDefault(name, defaultVaue) {
|
2
|
2
|
return rootProject.ext.has(name) ? rootProject.ext.get(name) : defaultVaue
|
3
|
3
|
}
|
4
|
4
|
|
|
5
|
+buildscript {
|
|
6
|
+ // The Android Gradle plugin is only required when opening the android folder stand-alone.
|
|
7
|
+ // This avoids unnecessary downloads and potential conflicts when the library is included as a
|
|
8
|
+ // module dependency in an application project.
|
|
9
|
+ if (project == rootProject) {
|
|
10
|
+ repositories {
|
|
11
|
+ google()
|
|
12
|
+ jcenter()
|
|
13
|
+ }
|
|
14
|
+ dependencies {
|
|
15
|
+ classpath 'com.android.tools.build:gradle:3.5.0'
|
|
16
|
+ }
|
|
17
|
+ }
|
|
18
|
+}
|
|
19
|
+
|
5
|
20
|
apply plugin: 'com.android.library'
|
6
|
21
|
|
7
|
22
|
android {
|
|
@@ -16,6 +31,15 @@ android {
|
16
|
31
|
}
|
17
|
32
|
}
|
18
|
33
|
|
|
34
|
+repositories {
|
|
35
|
+ google()
|
|
36
|
+ maven {
|
|
37
|
+ // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
|
|
38
|
+ url "$rootDir/../node_modules/react-native/android"
|
|
39
|
+ }
|
|
40
|
+ jcenter()
|
|
41
|
+}
|
|
42
|
+
|
19
|
43
|
dependencies {
|
20
|
44
|
//noinspection GradleDynamicVersion
|
21
|
45
|
implementation 'com.facebook.react:react-native:+'
|