Skip to content

Commit 60d389e

Browse files
committed
chore: Upgrade example app to Expo SDK 55 / React Native 0.83
1 parent 33df27d commit 60d389e

File tree

15 files changed

+1392
-1592
lines changed

15 files changed

+1392
-1592
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ and this project attempts to adhere to [Semantic Versioning](https://semver.org/
2828

2929
- Rewrite app to use Turbo Native Modules.
3030
- Bump CI action versions to use Node 24.
31+
- Upgrade example app to Expo SDK 55 / RN 0.83.
3132

3233
## [2.5.0] - 2026-02-04
3334

example/android/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ def projectRoot = rootDir.getAbsoluteFile().getParentFile().getAbsolutePath()
1111
react {
1212
entryFile = file(["node", "-e", "require('expo/scripts/resolveAppEntry')", projectRoot, "android", "absolute"].execute(null, rootDir).text.trim())
1313
reactNativeDir = new File(["node", "--print", "require.resolve('react-native/package.json')"].execute(null, rootDir).text.trim()).getParentFile().getAbsoluteFile()
14-
hermesCommand = new File(["node", "--print", "require.resolve('react-native/package.json')"].execute(null, rootDir).text.trim()).getParentFile().getAbsolutePath() + "/sdks/hermesc/%OS-BIN%/hermesc"
14+
hermesCommand = new File(["node", "--print", "require.resolve('hermes-compiler/package.json', { paths: [require.resolve('react-native/package.json')] })"].execute(null, rootDir).text.trim()).getParentFile().getAbsolutePath() + "/hermesc/%OS-BIN%/hermesc"
1515
codegenDir = new File(["node", "--print", "require.resolve('@react-native/codegen/package.json', { paths: [require.resolve('react-native/package.json')] })"].execute(null, rootDir).text.trim()).getParentFile().getAbsoluteFile()
1616

1717
enableBundleCompression = (findProperty('android.enableBundleCompression') ?: false).toBoolean()

example/android/app/src/main/AndroidManifest.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools">
22
<uses-permission android:name="android.permission.INTERNET"/>
3-
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
3+
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" android:maxSdkVersion="32" tools:replace="android:maxSdkVersion"/>
44
<uses-permission android:name="android.permission.READ_MEDIA_AUDIO"/>
55
<uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/>
66
<uses-permission android:name="android.permission.READ_MEDIA_VIDEO"/>
77
<uses-permission android:name="android.permission.READ_MEDIA_VISUAL_USER_SELECTED"/>
88
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
99
<uses-permission android:name="android.permission.VIBRATE"/>
10-
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
10+
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:maxSdkVersion="32" tools:replace="android:maxSdkVersion"/>
1111
<queries>
1212
<intent>
1313
<action android:name="android.intent.action.VIEW"/>
@@ -19,7 +19,7 @@
1919
<meta-data android:name="expo.modules.updates.ENABLED" android:value="false"/>
2020
<meta-data android:name="expo.modules.updates.EXPO_UPDATES_CHECK_ON_LAUNCH" android:value="ALWAYS"/>
2121
<meta-data android:name="expo.modules.updates.EXPO_UPDATES_LAUNCH_WAIT_MS" android:value="0"/>
22-
<activity android:name=".MainActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|screenLayout|uiMode" android:launchMode="singleTask" android:windowSoftInputMode="adjustResize" android:theme="@style/Theme.App.SplashScreen" android:exported="true" android:screenOrientation="portrait">
22+
<activity android:name=".MainActivity" android:configChanges="keyboard|keyboardHidden|orientation|screenSize|screenLayout|uiMode|smallestScreenSize" android:launchMode="singleTask" android:windowSoftInputMode="adjustResize" android:theme="@style/Theme.App.SplashScreen" android:exported="true" android:screenOrientation="portrait">
2323
<intent-filter>
2424
<action android:name="android.intent.action.MAIN"/>
2525
<category android:name="android.intent.category.LAUNCHER"/>

example/android/app/src/main/java/com/anonymous/benchmarking/rnmr/MainApplication.kt

Lines changed: 11 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -6,37 +6,26 @@ import android.content.res.Configuration
66
import com.facebook.react.PackageList
77
import com.facebook.react.ReactApplication
88
import com.facebook.react.ReactNativeApplicationEntryPoint.loadReactNative
9-
import com.facebook.react.ReactNativeHost
109
import com.facebook.react.ReactPackage
1110
import com.facebook.react.ReactHost
1211
import com.facebook.react.common.ReleaseLevel
1312
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint
14-
import com.facebook.react.defaults.DefaultReactNativeHost
1513

1614
import expo.modules.ApplicationLifecycleDispatcher
17-
import expo.modules.ReactNativeHostWrapper
15+
import expo.modules.ExpoReactHostFactory
1816

1917
class MainApplication : Application(), ReactApplication {
2018

21-
override val reactNativeHost: ReactNativeHost = ReactNativeHostWrapper(
22-
this,
23-
object : DefaultReactNativeHost(this) {
24-
override fun getPackages(): List<ReactPackage> =
25-
PackageList(this).packages.apply {
26-
// Packages that cannot be autolinked yet can be added manually here, for example:
27-
// add(MyReactNativePackage())
28-
}
29-
30-
override fun getJSMainModuleName(): String = ".expo/.virtual-metro-entry"
31-
32-
override fun getUseDeveloperSupport(): Boolean = BuildConfig.DEBUG
33-
34-
override val isNewArchEnabled: Boolean = BuildConfig.IS_NEW_ARCHITECTURE_ENABLED
35-
}
36-
)
37-
38-
override val reactHost: ReactHost
39-
get() = ReactNativeHostWrapper.createReactHost(applicationContext, reactNativeHost)
19+
override val reactHost: ReactHost by lazy {
20+
ExpoReactHostFactory.getDefaultReactHost(
21+
context = applicationContext,
22+
packageList =
23+
PackageList(this).packages.apply {
24+
// Packages that cannot be autolinked yet can be added manually here, for example:
25+
// add(MyReactNativePackage())
26+
}
27+
)
28+
}
4029

4130
override fun onCreate() {
4231
super.onCreate()

example/android/app/src/main/res/values/colors.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,4 @@
22
<color name="splashscreen_background">#ffffff</color>
33
<color name="iconBackground">#E6F4FE</color>
44
<color name="colorPrimary">#023c69</color>
5-
<color name="colorPrimaryDark">#ffffff</color>
65
</resources>
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
<resources>
22
<string name="app_name">RNMR Benchmarking</string>
33
<string name="expo_splash_screen_resize_mode" translatable="false">contain</string>
4-
<string name="expo_splash_screen_status_bar_translucent" translatable="false">false</string>
54
</resources>

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
<resources xmlns:tools="http://schemas.android.com/tools">
22
<style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
3-
<item name="android:enforceNavigationBarContrast" tools:targetApi="29">true</item>
43
<item name="android:editTextBackground">@drawable/rn_edit_text_material</item>
54
<item name="colorPrimary">@color/colorPrimary</item>
6-
<item name="android:statusBarColor">#ffffff</item>
5+
<item name="android:statusBarColor">@android:color/transparent</item>
6+
<item name="android:navigationBarColor">@android:color/transparent</item>
77
</style>
88
<style name="Theme.App.SplashScreen" parent="AppTheme">
99
<item name="android:windowBackground">@drawable/ic_launcher_background</item>

example/android/gradle.properties

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,6 @@ EX_DEV_CLIENT_NETWORK_INSPECTOR=true
6060
# Use legacy packaging to compress native libraries in the resulting APK.
6161
expo.useLegacyPackaging=false
6262

63-
# Specifies whether the app is configured to use edge-to-edge via the app config or plugin
64-
# WARNING: This property has been deprecated and will be removed in Expo SDK 55. Use `edgeToEdgeEnabled` or `react.edgeToEdgeEnabled` to determine whether the project is using edge-to-edge.
65-
expo.edgeToEdgeEnabled=true
66-
6763
android.enableMinifyInReleaseBuilds=true
6864
android.enableShrinkResourcesInReleaseBuilds=true
6965
android.enableBundleCompression=true
1.65 KB
Binary file not shown.

example/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

0 commit comments

Comments
 (0)