Migrate ReactNativeHost from Java to Kotlin (#56848)#56848
Closed
cortinico wants to merge 1 commit into
Closed
Conversation
|
@cortinico has exported this pull request. If you are a Meta employee, you can view the originating Diff in D105013283. |
a4fedf9 to
62629b3
Compare
cortinico
added a commit
to cortinico/react-native
that referenced
this pull request
May 20, 2026
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
62629b3 to
45eecf3
Compare
45eecf3 to
c5365d3
Compare
cortinico
added a commit
to cortinico/react-native
that referenced
this pull request
May 21, 2026
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
cortinico
added a commit
to cortinico/react-native
that referenced
this pull request
May 21, 2026
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
c5365d3 to
18a8598
Compare
cortinico
added a commit
to cortinico/react-native
that referenced
this pull request
May 21, 2026
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
18a8598 to
5c7a660
Compare
cortinico
added a commit
to cortinico/react-native
that referenced
this pull request
May 21, 2026
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
5c7a660 to
60bcdcd
Compare
cortinico
added a commit
to cortinico/react-native
that referenced
this pull request
May 21, 2026
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
60bcdcd to
0e562a3
Compare
Summary: Pull Request resolved: react#56848 Mechanical migration of the deprecated `ReactNativeHost` class from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility. Key migration decisions: - Class remains `abstract` (implicitly open) - All non-final, non-abstract methods marked `open` to match Java virtual-by-default - `getApplication()` remains `final` (no `open`) - Methods kept as explicit `fun` (not Kotlin properties) to preserve exact JVM getter names like `getJSMainModuleName()`, `getJSBundleFile()`, `getUIManagerProvider()` - `Nullable` return types converted to Kotlin nullable types (`?`) - `synchronized` methods use `Synchronized` annotation - `Nullsafe` annotation removed (redundant in Kotlin) - Static initializer converted to companion object `init` block Changelog: [Android][Changed] - Migrate `ReactNativeHost` from Java to Kotlin (no behavioral changes) Reviewed By: javache Differential Revision: D105013283
0e562a3 to
0a74b65
Compare
|
This pull request has been merged in 7eb1133. |
Collaborator
|
This pull request was successfully merged by @cortinico in 7eb1133 When will my fix make it into a release? | How to file a pick request? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Mechanical migration of the deprecated
ReactNativeHostclass from Java to Kotlin. All methods retain their exact JVM signatures to preserve API compatibility.Key migration decisions:
abstract(implicitly open)opento match Java virtual-by-defaultgetApplication()remainsfinal(noopen)fun(not Kotlin properties) to preserve exact JVM getter names likegetJSMainModuleName(),getJSBundleFile(),getUIManagerProvider()Nullablereturn types converted to Kotlin nullable types (?)synchronizedmethods useSynchronizedannotationNullsafeannotation removed (redundant in Kotlin)initblockChangelog:
[Android][Changed] - Migrate
ReactNativeHostfrom Java to Kotlin (no behavioral changes)Reviewed By: javache
Differential Revision: D105013283