Skip to content

☂️ Help us Kotlin-ify React Native - Round 3 #50513

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
11 of 12 tasks
mateoguzmana opened this issue Apr 7, 2025 · 25 comments
Open
11 of 12 tasks

☂️ Help us Kotlin-ify React Native - Round 3 #50513

mateoguzmana opened this issue Apr 7, 2025 · 25 comments
Labels
Good first issue Interested in collaborating? Take a stab at fixing one of these issues. Help Wanted :octocat: Issues ideal for external contributors. ☂️ Umbrella To label issues that serve as coordination point and drivers for tasks in the react-native repo

Comments

@mateoguzmana
Copy link
Collaborator

mateoguzmana commented Apr 7, 2025

☂️ Help us Kotlin-ify React Native - Round 3

Hey all 👋
After the successful second round, we're back with another round of tasks to help us improve Kotlin support in React Native core. In this stage we are looking for help to migrate a few more files to Kotlin.

How to work

If you wish to grab one of the tasks, you should:

  • Verify that the task is not claimed yet.
  • Comment here that you claim a task.
  • Start working on the task. Testing instructions are below.
  • Send the PR for review. Ping @mateoguzmana, @cortinico or @mdvacca for a review.
  • You can’t claim more than one task at a time.
  • If you’re not completing the task within a week, we’ll release it for the next contributor.

Code formatting

Please use KtFmt to format Kotlin classes.
You can use the web UI to reformat directly from the browser.

Migrating files to Kotlin

Please act as follow:

  • Fork and clone the repo
  • Verify that RN-Tester, our reference app, runs with yarn && yarn android from the root folder
  • Migrate the file to Kotlin
  • Verify that RN-Tester runs again using the same command.

Other important things to take into account:

  • Avoid using Hungarian notation for the variables when the file is migrated. E.g.: mMyAwesomeProperty should become myAwesomeProperty
  • You might have to run the project in old architecture as well to ensure nothing breaks there when building. You can easily switch in the RN-Tester by setting newArchEnabled=false in packages/rn-tester/android/app/gradle.properties
  • Tap around in a few screens after migrating (helps to ensure nothing is breaking at runtime)

List of files to migrate

@react-native-bot react-native-bot added Needs: Author Feedback Needs: Repro This issue could be improved with a clear list of steps to reproduce the issue. labels Apr 7, 2025
@mateoguzmana mateoguzmana removed Needs: Author Feedback Needs: Repro This issue could be improved with a clear list of steps to reproduce the issue. labels Apr 7, 2025
@facebook facebook deleted a comment from react-native-bot Apr 7, 2025
@facebook facebook deleted a comment from react-native-bot Apr 7, 2025
@facebook facebook deleted a comment from react-native-bot Apr 7, 2025
@mateoguzmana mateoguzmana added ☂️ Umbrella To label issues that serve as coordination point and drivers for tasks in the react-native repo Good first issue Interested in collaborating? Take a stab at fixing one of these issues. Help Wanted :octocat: Issues ideal for external contributors. labels Apr 7, 2025
@cortinico cortinico changed the title DRAFT – ☂️ Help us Kotlin-ify React Native tests - Round 3 ☂️ Help us Kotlin-ify React Native tests - Round 3 Apr 7, 2025
@cortinico cortinico pinned this issue Apr 7, 2025
@cortinico
Copy link
Contributor

Let's go 🚀

@devanshsaini11
Copy link
Collaborator

I would like to migrate: react/modules/blob/FileReaderModule.java

@JatinDream11
Copy link

I would like to migrate react/modules/blob/BlobProvider.java

@yasir6jan
Copy link
Contributor

I would like to migrate react/bridge/DynamicFromObject.java

@poonamjain96
Copy link
Contributor

I would like to migrate react/uimanager/ReactStylesDiffMap.java

@mateoguzmana mateoguzmana changed the title ☂️ Help us Kotlin-ify React Native tests - Round 3 ☂️ Help us Kotlin-ify React Native - Round 3 Apr 7, 2025
@Q1w1N
Copy link
Contributor

Q1w1N commented Apr 7, 2025

I would like to migrate react/views/textinput/ReactEditTextInputConnectionWrapper.java

@BogiKay
Copy link
Contributor

BogiKay commented Apr 7, 2025

I'd like to migrate react/bridge/DynamicFromArray.java

@artus9033
Copy link
Contributor

artus9033 commented Apr 7, 2025

Hello, I'd like to migrate react/bridge/DynamicFromMap.java

Edit: tracked in #50597

@rohitverma-d11
Copy link
Contributor

Hello, I'd like to migrate react/runtime/ReactLifecycleStateManager.java

@riteshshukla04
Copy link
Contributor

riteshshukla04 commented Apr 7, 2025

react/bridge/UiThreadUtil.java

Can you assign me this @mateoguzmana

@gouravkhunger
Copy link
Contributor

Hi @mateoguzmana I could help with react/views/text/frescosupport/FrescoBasedReactTextInlineImageSpan.java

@gustavoabel
Copy link
Contributor

@mateoguzmana Hello, if any file remains pending, please assign it to me.

facebook-github-bot pushed a commit that referenced this issue Apr 8, 2025
Summary:
This PR aims to migrate UiThreadUtil  from Java to kotlin as part of #50513

## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests
-->
[ANDROID][CHANGED]Migrate UiThreadUtil to Kotlin

Pull Request resolved: #50536

Test Plan: Tested on RN tester with both new and old arch

Reviewed By: cortinico

Differential Revision: D72602041

Pulled By: arushikesarwani94

fbshipit-source-id: 9f45a139805819a21039eb640a0bd1583a3acde9
facebook-github-bot pushed a commit that referenced this issue Apr 10, 2025
Summary:
This PR aims to migrate FileReaderModule from Java to kotlin as part of #50513

## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests
-->
[ANDROID][CHANGED]Migrate FileReaderModule to Kotlin

Pull Request resolved: #50562

Test Plan: Tested on RN tester with both new and old arch

Reviewed By: arushikesarwani94

Differential Revision: D72726333

Pulled By: cortinico

fbshipit-source-id: 130393373a258f18f8baaa96745da8fdebd62436
facebook-github-bot pushed a commit that referenced this issue Apr 11, 2025
Summary:
This PR introduces a rewrite of `DynamicFromMap.java` to Kotlin as requested in #50513.

## Changelog:

[ANDROID] [CHANGED] - Migrated `DynamicFromMap.java` to Kotlin

Pull Request resolved: #50597

Test Plan:
1. Implement unit tests for `DynamicFromMap.kt` - `DynamicFromMapTests.kt`
2. Ensure the tests pass: `./gradlew test`
3. Run the RN tester app on new & on old architectures

Reviewed By: javache, rshest

Differential Revision: D72853616

Pulled By: cortinico

fbshipit-source-id: 855acdc7fa7810ab9f223b0be7778c028a646de5
@rohitverma-d11
Copy link
Contributor

PR for Kotlin-ify react/runtime/ReactLifecycleStateManager.java

#50685

@nitinshukla413
Copy link
Contributor

@nitinshukla413
Copy link
Contributor

@rshest @mateoguzmana
I have resolved the comments for #50693 , Can you check?

@mateoguzmana
Copy link
Collaborator Author

Hi @JatinDream11 @yasir6jan, just checking in — could you share an update on your files? Otherwise, we’ll go ahead and release them.

@yasir6jan
Copy link
Contributor

Hi @mateoguzmana I am working on this and will be raising the PR by tomorrow.

@yogeshpaliyal
Copy link

yogeshpaliyal commented Apr 14, 2025

Hello, I wanted to contribute to React Native from a long time, looks like this can be a good start.

Please assign me any files we want to migrate to kotlin.

facebook-github-bot pushed a commit that referenced this issue Apr 15, 2025
Summary:
This PR aims to migrate ReactStylesDiffMap from Java to kotlin as part of #50513

## Changelog:
[ANDROID][CHANGED]Migrate ReactStylesDiffMap to Kotlin

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: #50616

Test Plan: Tested on RN tester with both new and old arch

Reviewed By: alanleedev

Differential Revision: D72962016

Pulled By: cortinico

fbshipit-source-id: 4de63ab78cd692822c01b5964209000c9d41f595
@Vin-Xi
Copy link
Contributor

Vin-Xi commented Apr 15, 2025

Hi,

If the migration for this file becomes available, react/modules/blob/BlobProvider.java, or any other file.

I would love to pick a file to migrate.

@JatinDream11
Copy link

Hi, I am currently busy with some urgent work. I will complete the migration of react/modules/blob/BlobProvider.java by thursday

@yasir6jan
Copy link
Contributor

yasir6jan commented Apr 16, 2025

Hi @mateoguzmana I have raised the PR but I am getting some conflicts, resolving those
#50754

@JatinDream11
Copy link

Hi @mateoguzmana I have raised the PR #50756

facebook-github-bot pushed a commit that referenced this issue Apr 17, 2025
Summary:
I've migrated `FrescoBasedTextInlineImageSpan.java` to kotlin. Reference #50513.

## Changelog:

[ANDROID] [CHANGED] - Refactor class `FrescoBasedTextInlineImageSpan` from Java to Kotlin.

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: #50532

Test Plan: Tested the RN tester app with `yarn android` on both new and old architecture.

Reviewed By: rshest

Differential Revision: D73031024

Pulled By: cortinico

fbshipit-source-id: e7208bf1103849f38c3dc26d73b31315b2326275
facebook-github-bot pushed a commit that referenced this issue Apr 17, 2025
Summary:
PR migrates DynamicFromArray class to Kotlin as part of #50513 work.

## Changelog:

[ANDROID] [CHANGED] - Migrated DynamicFromArray to Kotlin

Pull Request resolved: #50602

Test Plan: Run RN-Tester application and played around with it a bit.

Reviewed By: rshest

Differential Revision: D73179609

Pulled By: cortinico

fbshipit-source-id: e304884fea9f57e152bca4926677d7338dc2403a
facebook-github-bot pushed a commit that referenced this issue Apr 17, 2025
Summary:
PR migrates DynamicFromObject class to Kotlin as part of #50513 work.

## Changelog:

[ANDROID] [CHANGED] - Migrated DynamicFromObject to Kotlin

Pull Request resolved: #50754

Test Plan: Run RN-Tester application and played around with it a bit.

Reviewed By: mlord93

Differential Revision: D73118014

Pulled By: alanleedev

fbshipit-source-id: 84958ff07ccafea9ec3dbdf06467c638eb92d49d
uffoltzl pushed a commit to uffoltzl/react-native that referenced this issue Apr 18, 2025
Summary:
This PR introduces a rewrite of `DynamicFromMap.java` to Kotlin as requested in facebook#50513.

## Changelog:

[ANDROID] [CHANGED] - Migrated `DynamicFromMap.java` to Kotlin

Pull Request resolved: facebook#50597

Test Plan:
1. Implement unit tests for `DynamicFromMap.kt` - `DynamicFromMapTests.kt`
2. Ensure the tests pass: `./gradlew test`
3. Run the RN tester app on new & on old architectures

Reviewed By: javache, rshest

Differential Revision: D72853616

Pulled By: cortinico

fbshipit-source-id: 855acdc7fa7810ab9f223b0be7778c028a646de5
uffoltzl pushed a commit to uffoltzl/react-native that referenced this issue Apr 18, 2025
Summary:
This PR aims to migrate ReactStylesDiffMap from Java to kotlin as part of facebook#50513

## Changelog:
[ANDROID][CHANGED]Migrate ReactStylesDiffMap to Kotlin

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: facebook#50616

Test Plan: Tested on RN tester with both new and old arch

Reviewed By: alanleedev

Differential Revision: D72962016

Pulled By: cortinico

fbshipit-source-id: 4de63ab78cd692822c01b5964209000c9d41f595
uffoltzl pushed a commit to uffoltzl/react-native that referenced this issue Apr 18, 2025
Summary:
I've migrated `FrescoBasedTextInlineImageSpan.java` to kotlin. Reference facebook#50513.

## Changelog:

[ANDROID] [CHANGED] - Refactor class `FrescoBasedTextInlineImageSpan` from Java to Kotlin.

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: facebook#50532

Test Plan: Tested the RN tester app with `yarn android` on both new and old architecture.

Reviewed By: rshest

Differential Revision: D73031024

Pulled By: cortinico

fbshipit-source-id: e7208bf1103849f38c3dc26d73b31315b2326275
uffoltzl pushed a commit to uffoltzl/react-native that referenced this issue Apr 18, 2025
Summary:
PR migrates DynamicFromArray class to Kotlin as part of facebook#50513 work.

## Changelog:

[ANDROID] [CHANGED] - Migrated DynamicFromArray to Kotlin

Pull Request resolved: facebook#50602

Test Plan: Run RN-Tester application and played around with it a bit.

Reviewed By: rshest

Differential Revision: D73179609

Pulled By: cortinico

fbshipit-source-id: e304884fea9f57e152bca4926677d7338dc2403a
uffoltzl pushed a commit to uffoltzl/react-native that referenced this issue Apr 18, 2025
Summary:
PR migrates DynamicFromObject class to Kotlin as part of facebook#50513 work.

## Changelog:

[ANDROID] [CHANGED] - Migrated DynamicFromObject to Kotlin

Pull Request resolved: facebook#50754

Test Plan: Run RN-Tester application and played around with it a bit.

Reviewed By: mlord93

Differential Revision: D73118014

Pulled By: alanleedev

fbshipit-source-id: 84958ff07ccafea9ec3dbdf06467c638eb92d49d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Good first issue Interested in collaborating? Take a stab at fixing one of these issues. Help Wanted :octocat: Issues ideal for external contributors. ☂️ Umbrella To label issues that serve as coordination point and drivers for tasks in the react-native repo
Projects
None yet
Development

No branches or pull requests