From a0771fa74163d2501d839d340adb0e35711da9f2 Mon Sep 17 00:00:00 2001
From: Tommy Nguyen <4123478+tido64@users.noreply.github.com>
Date: Mon, 21 Jul 2025 06:59:31 +0200
Subject: [PATCH 1/5] fix(android): bump Gradle wrapper version for 0.80+
---
android/gradle-wrapper.js | 2 +-
test/android/gradle-wrapper.test.ts | 4 ++--
tsconfig.cjs.json | 2 +-
tsconfig.json | 2 +-
yarn.lock | 6 +++---
5 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/android/gradle-wrapper.js b/android/gradle-wrapper.js
index 99d6b5709..1b7f9d5c8 100644
--- a/android/gradle-wrapper.js
+++ b/android/gradle-wrapper.js
@@ -34,7 +34,7 @@ const INT_MAX = 2 ** 31 - 1;
* @type {[number, [number, string], [number, string]][]}
*/
const GRADLE_VERSIONS = [
- [v(0, 80, 0), [v(8, 14, 1), "8.14.1"], [INT_MAX, ""]], // 0.80: [8.14.1, *)
+ [v(0, 80, 0), [v(8, 14, 3), "8.14.3"], [INT_MAX, ""]], // 0.80: [8.14.3, *)
[v(0, 79, 0), [v(8, 13, 0), "8.13"], [INT_MAX, ""]], // 0.79: [8.13, *)
[v(0, 78, 0), [v(8, 12, 0), "8.12"], [INT_MAX, ""]], // 0.78: [8.12, *)
[v(0, 76, 0), [v(8, 11, 1), "8.11.1"], [INT_MAX, ""]], // 0.76: [8.11.1, *)
diff --git a/test/android/gradle-wrapper.test.ts b/test/android/gradle-wrapper.test.ts
index d23e3b6a7..e5f3b3303 100644
--- a/test/android/gradle-wrapper.test.ts
+++ b/test/android/gradle-wrapper.test.ts
@@ -135,7 +135,7 @@ describe("configureGradleWrapper()", () => {
process.argv.push("run-android");
const cases = [
- ["8.14", "0.80.0", "gradle-8.14.1-bin.zip"],
+ ["8.14", "0.80.0", "gradle-8.14.3-bin.zip"],
["8.12", "0.79.0", "gradle-8.13-bin.zip"],
["8.11.1", "0.78.0", "gradle-8.12-bin.zip"],
["8.9", "0.76.0", "gradle-8.11.1-bin.zip"],
@@ -193,7 +193,7 @@ describe("configureGradleWrapper()", () => {
process.argv.push("run-android");
const cases = [
- ["8.14.1", "0.80.0"],
+ ["8.14.3", "0.80.0"],
["8.13", "0.79.0"],
["8.12", "0.78.0"],
["8.11.1", "0.76.0"],
diff --git a/tsconfig.cjs.json b/tsconfig.cjs.json
index e1a0d9ddb..f0a7e1aba 100644
--- a/tsconfig.cjs.json
+++ b/tsconfig.cjs.json
@@ -1,5 +1,5 @@
{
- "extends": "@rnx-kit/tsconfig/tsconfig.json",
+ "extends": "@rnx-kit/tsconfig/tsconfig.node.json",
"compilerOptions": {
"noEmit": true
},
diff --git a/tsconfig.json b/tsconfig.json
index 7a2637809..802bc6799 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -1,5 +1,5 @@
{
- "extends": "@rnx-kit/tsconfig/tsconfig.esm.json",
+ "extends": "@rnx-kit/tsconfig/tsconfig.esm.node.json",
"compilerOptions": {
"target": "ES2022",
"module": "ES2022",
diff --git a/yarn.lock b/yarn.lock
index a24466647..8a4ae70d1 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -3960,9 +3960,9 @@ __metadata:
linkType: hard
"@rnx-kit/tsconfig@npm:^2.0.0":
- version: 2.0.1
- resolution: "@rnx-kit/tsconfig@npm:2.0.1"
- checksum: 10c0/28acc7c2d82be18dd3ec360222ece40981c137b6532df39ffbfdc7996af9818e6abf2a1f583923be07faf06ce8bf3a0b95c3d41680d67b05459a0d7ad4ed4235
+ version: 2.1.1
+ resolution: "@rnx-kit/tsconfig@npm:2.1.1"
+ checksum: 10c0/53aed185abd644250d95c732e44ecb66bcdf3005cc6eb854ba217346fa29cf0ea892bbd391e15050a5b553fe7dc983130add30c9aa30b1f66a0ca498d3409d94
languageName: node
linkType: hard
From 9d11e45e03c0208eb22f97cbb601c2cefe9d71e3 Mon Sep 17 00:00:00 2001
From: Tommy Nguyen <4123478+tido64@users.noreply.github.com>
Date: Mon, 21 Jul 2025 07:30:17 +0200
Subject: [PATCH 2/5] format/lint Swift files
---
.swiftlint.yml | 2 ++
ios/ReactTestApp/ContentView.swift | 18 +++++++++---------
ios/ReactTestApp/ReactInstance.swift | 2 +-
3 files changed, 12 insertions(+), 10 deletions(-)
diff --git a/.swiftlint.yml b/.swiftlint.yml
index 579ad592e..73cafc2d8 100644
--- a/.swiftlint.yml
+++ b/.swiftlint.yml
@@ -3,6 +3,8 @@ disabled_rules:
- opening_brace # Conflicts with SwiftFormat
- trailing_comma
excluded:
+ - example/*/DerivedData/
- example/*/Pods/
+ - example/*/build/
- example/node_modules/
- node_modules/
diff --git a/ios/ReactTestApp/ContentView.swift b/ios/ReactTestApp/ContentView.swift
index 0673fb730..cd1ba6c91 100644
--- a/ios/ReactTestApp/ContentView.swift
+++ b/ios/ReactTestApp/ContentView.swift
@@ -39,7 +39,7 @@ final class ContentViewController: UITableViewController {
private let reactInstance: ReactInstance
private var sections: [SectionData]
- public init(reactInstance: ReactInstance) {
+ init(reactInstance: ReactInstance) {
self.reactInstance = reactInstance
sections = []
@@ -53,7 +53,7 @@ final class ContentViewController: UITableViewController {
// MARK: - UIResponder overrides
- override public func motionEnded(_: UIEvent.EventSubtype, with event: UIEvent?) {
+ override func motionEnded(_: UIEvent.EventSubtype, with event: UIEvent?) {
guard event?.subtype == .motionShake, let host = reactInstance.host else {
return
}
@@ -73,7 +73,7 @@ final class ContentViewController: UITableViewController {
// MARK: - UIViewController overrides
- override public func viewDidLoad() {
+ override func viewDidLoad() {
super.viewDidLoad()
let manifest = Manifest.load()
@@ -154,21 +154,21 @@ final class ContentViewController: UITableViewController {
// MARK: - UITableViewDelegate overrides
- override public func tableView(_: UITableView, shouldHighlightRowAt indexPath: IndexPath) -> Bool {
+ override func tableView(_: UITableView, shouldHighlightRowAt indexPath: IndexPath) -> Bool {
indexPath.section == Section.components
}
- override public func tableView(_: UITableView, didSelectRowAt indexPath: IndexPath) {
+ override func tableView(_: UITableView, didSelectRowAt indexPath: IndexPath) {
sections[indexPath.section].items[indexPath.row].action?()
}
// MARK: - UITableViewDataSource overrides
- override public func tableView(_: UITableView, numberOfRowsInSection section: Int) -> Int {
+ override func tableView(_: UITableView, numberOfRowsInSection section: Int) -> Int {
sections[section].items.count
}
- override public func tableView(_: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
+ override func tableView(_: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let link = sections[indexPath.section].items[indexPath.row]
let cell = UITableViewCell(style: .default, reuseIdentifier: "cell")
@@ -193,11 +193,11 @@ final class ContentViewController: UITableViewController {
return cell
}
- override public func numberOfSections(in _: UITableView) -> Int {
+ override func numberOfSections(in _: UITableView) -> Int {
sections.count
}
- override public func tableView(_: UITableView, titleForFooterInSection section: Int) -> String? {
+ override func tableView(_: UITableView, titleForFooterInSection section: Int) -> String? {
sections[section].footer
}
diff --git a/ios/ReactTestApp/ReactInstance.swift b/ios/ReactTestApp/ReactInstance.swift
index ddbe75101..caba18a7d 100644
--- a/ios/ReactTestApp/ReactInstance.swift
+++ b/ios/ReactTestApp/ReactInstance.swift
@@ -3,7 +3,7 @@ import ReactNativeHost
import ReactTestApp_DevSupport
final class ReactInstance: NSObject, RNXHostConfig {
- public static let scanForQRCodeNotification =
+ static let scanForQRCodeNotification =
NSNotification.Name("ReactInstance.scanForQRCodeNotification")
static func jsBundleURL() -> URL? {
From 25b18748a3e56545555cd95f5d047387bbbbb7d0 Mon Sep 17 00:00:00 2001
From: Tommy Nguyen <4123478+tido64@users.noreply.github.com>
Date: Mon, 21 Jul 2025 08:33:49 +0200
Subject: [PATCH 3/5] downgrade Node on Windows
---
.github/workflows/build.yml | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 3838a044e..8c8094692 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -553,6 +553,7 @@ jobs:
uses: ./.github/actions/setup-toolchain
with:
platform: windows
+ node-version: "22.16"
- name: Set up react-native@canary
if: ${{ github.event_name == 'schedule' }}
uses: ./.github/actions/setup-react-native
@@ -610,6 +611,7 @@ jobs:
uses: ./.github/actions/setup-toolchain
with:
platform: windows
+ node-version: "22.16"
- name: Initialize test app
uses: ./.github/actions/init-test-app
with:
From d49f720631ecb87a17d3427bd614dfdc07b9445a Mon Sep 17 00:00:00 2001
From: Tommy Nguyen <4123478+tido64@users.noreply.github.com>
Date: Mon, 21 Jul 2025 09:03:51 +0200
Subject: [PATCH 4/5] Revert "downgrade Node on Windows"
This reverts commit 25b18748a3e56545555cd95f5d047387bbbbb7d0.
---
.github/workflows/build.yml | 2 --
windows/app.mjs | 2 +-
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 8c8094692..3838a044e 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -553,7 +553,6 @@ jobs:
uses: ./.github/actions/setup-toolchain
with:
platform: windows
- node-version: "22.16"
- name: Set up react-native@canary
if: ${{ github.event_name == 'schedule' }}
uses: ./.github/actions/setup-react-native
@@ -611,7 +610,6 @@ jobs:
uses: ./.github/actions/setup-toolchain
with:
platform: windows
- node-version: "22.16"
- name: Initialize test app
uses: ./.github/actions/init-test-app
with:
diff --git a/windows/app.mjs b/windows/app.mjs
index d719e045a..ee936fda5 100755
--- a/windows/app.mjs
+++ b/windows/app.mjs
@@ -258,7 +258,7 @@ export async function generateSolution(destPath, options, fs = nodefs) {
const { msbuildprops, useHermes } = options;
const { useExperimentalNuGet, useFabric, versionNumber } = info;
const url = new URL(experimentalFeaturesPropsFilename, import.meta.url);
- copyAndReplaceAsync(fileURLToPath(url), experimentalFeaturesPropsPath, {
+ await copyAndReplaceAsync(fileURLToPath(url), experimentalFeaturesPropsPath, {
"false": `${useFabric}`,
"false": `${useFabric}`,
"true": `${useHermes == null ? versionNumber >= v(0, 73, 0) : useHermes}`,
From 22752c169939457d4f6e7c892ba8e75e96a18f94 Mon Sep 17 00:00:00 2001
From: Tommy Nguyen <4123478+tido64@users.noreply.github.com>
Date: Mon, 21 Jul 2025 09:15:27 +0200
Subject: [PATCH 5/5] format
---
windows/app.mjs | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
diff --git a/windows/app.mjs b/windows/app.mjs
index ee936fda5..85d21096b 100755
--- a/windows/app.mjs
+++ b/windows/app.mjs
@@ -258,14 +258,18 @@ export async function generateSolution(destPath, options, fs = nodefs) {
const { msbuildprops, useHermes } = options;
const { useExperimentalNuGet, useFabric, versionNumber } = info;
const url = new URL(experimentalFeaturesPropsFilename, import.meta.url);
- await copyAndReplaceAsync(fileURLToPath(url), experimentalFeaturesPropsPath, {
- "false": `${useFabric}`,
- "false": `${useFabric}`,
- "true": `${useHermes == null ? versionNumber >= v(0, 73, 0) : useHermes}`,
- "false": `${useFabric}`,
- "false": `${useExperimentalNuGet}`,
- "": msbuildprops ?? "",
- });
+ await copyAndReplaceAsync(
+ fileURLToPath(url),
+ experimentalFeaturesPropsPath,
+ {
+ "false": `${useFabric}`,
+ "false": `${useFabric}`,
+ "true": `${useHermes == null ? versionNumber >= v(0, 73, 0) : useHermes}`,
+ "false": `${useFabric}`,
+ "false": `${useExperimentalNuGet}`,
+ "": msbuildprops ?? "",
+ }
+ );
}
if (info.useExperimentalNuGet) {