Skip to content

Commit 1863a71

Browse files
committed
upgrade to rn66
1 parent 17cb7aa commit 1863a71

File tree

13 files changed

+362
-324
lines changed

13 files changed

+362
-324
lines changed
File renamed without changes.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ build/
3737
.gradle
3838
local.properties
3939
*.iml
40+
*.hprof
4041

4142
# node.js
4243
#

android/app/build.gradle

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,18 +15,17 @@ def enableProguardInReleaseBuilds = false
1515
def jscFlavor = 'org.webkit:android-jsc:+'
1616
def enableHermes = project.ext.react.get("enableHermes", false)
1717

18+
/**
19+
* Architectures to build native code for in debug.
20+
*/
21+
def nativeArchitectures = project.getProperties().get("reactNativeDebugArchitectures")
22+
1823
android {
1924
ndkVersion rootProject.ext.ndkVersion
2025

2126
compileSdkVersion rootProject.ext.compileSdkVersion
2227
buildToolsVersion rootProject.ext.buildToolsVersion
2328

24-
25-
compileOptions {
26-
sourceCompatibility JavaVersion.VERSION_1_8
27-
targetCompatibility JavaVersion.VERSION_1_8
28-
}
29-
3029
defaultConfig {
3130
applicationId "com.calendarsexample"
3231
minSdkVersion rootProject.ext.minSdkVersion
@@ -53,6 +52,11 @@ android {
5352
buildTypes {
5453
debug {
5554
signingConfig signingConfigs.debug
55+
if (nativeArchitectures) {
56+
ndk {
57+
abiFilters nativeArchitectures.split(',')
58+
}
59+
}
5660
}
5761
release {
5862
// Caution! In production, you need to generate your own keystore file.
@@ -106,7 +110,7 @@ dependencies {
106110
// Run this once to be able to run the application with BUCK
107111
// puts all compile dependencies into folder libs for BUCK to use
108112
task copyDownloadableDepsToLibs(type: Copy) {
109-
from configurations.compile
113+
from configurations.implementation
110114
into 'libs'
111115
}
112116

android/app/src/main/res/values/styles.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
<!-- Base application theme. -->
44
<style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
55
<!-- Customize your theme here. -->
6-
<item name="android:textColor">#000000</item>
76
</style>
87

98
</resources>

android/build.gradle

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,30 @@
22

33
buildscript {
44
ext {
5-
buildToolsVersion = "29.0.3"
5+
buildToolsVersion = "30.0.2"
66
minSdkVersion = 21
7-
compileSdkVersion = 29
8-
targetSdkVersion = 29
9-
ndkVersion = "20.1.5948944"
7+
compileSdkVersion = 30
8+
targetSdkVersion = 30
9+
ndkVersion = "21.4.7075529"
1010
supportLibVersion = "29.0.0"
11-
RNNKotlinVersion = "1.3.72"
11+
RNNKotlinVersion = "1.6.0"
1212
}
1313
repositories {
1414
google()
15-
jcenter()
1615
mavenLocal()
1716
mavenCentral()
1817
}
1918
dependencies {
20-
classpath("com.android.tools.build:gradle:4.1.0")
21-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.72"
19+
classpath("com.android.tools.build:gradle:4.2.2")
20+
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$RNNKotlinVersion"
2221
// NOTE: Do not place your application dependencies here; they belong
2322
// in the individual module build.gradle files
2423
}
2524
}
2625

2726
allprojects {
2827
repositories {
28+
mavenCentral()
2929
mavenLocal()
3030
google()
3131
jcenter()

android/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@ android.useAndroidX=true
2222
android.enableJetifier=true
2323

2424
# Version of flipper SDK to use with React Native
25-
FLIPPER_VERSION=0.75.1
25+
FLIPPER_VERSION=0.99.0
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#Wed Mar 27 10:33:44 IST 2019
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
4-
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
4+
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-all.zip
55
zipStoreBase=GRADLE_USER_HOME
66
zipStorePath=wrapper/dists

example/.flowconfig

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ flow/
2424
[options]
2525
emoji=true
2626

27+
format.bracket_spacing=false
28+
2729
module.system=haste
2830

2931
munge_underscores=true
@@ -42,4 +44,4 @@ suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
4244
unsafe.enable_getters_and_setters=true
4345

4446
[version]
45-
^0.92.0
47+
^0.158.0

ios/CalendarsExample.xcodeproj/project.pbxproj

Lines changed: 47 additions & 45 deletions
Large diffs are not rendered by default.

ios/CalendarsExample/AppDelegate.m

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,9 @@ @implementation AppDelegate
99
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
1010
{
1111
NSURL *jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
12-
[ReactNativeNavigation bootstrap:jsCodeLocation launchOptions:launchOptions];
13-
12+
// [ReactNativeNavigation bootstrap:jsCodeLocation launchOptions:launchOptions];
13+
[ReactNativeNavigation bootstrapWithDelegate:self launchOptions:launchOptions];
14+
1415

1516
// NSURL *jsCodeLocation;
1617
//#ifdef DEBUG
@@ -54,4 +55,8 @@ - (NSURL *)sourceURLForBridge:(RCTBridge *)bridge
5455
#endif
5556
}
5657

58+
- (NSArray<id<RCTBridgeModule>> *)extraModulesForBridge:(RCTBridge *)bridge {
59+
return [ReactNativeNavigation extraModulesForBridge:bridge];
60+
}
61+
5762
@end

0 commit comments

Comments
 (0)