Skip to content
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

feat: enable inlining RN entrypoints #872

Merged
merged 2 commits into from
Jan 16, 2025

Conversation

jbroma
Copy link
Member

@jbroma jbroma commented Jan 16, 2025

Summary

Looking over the RN codebase I've found that ReactNativePrivateInitializeCore reexports InitializeCore. Inside commit history we can find attempts at making this module a noop but ultimately it was always reverted because of issues at metro.

We're not using metro and this isn't an issue with webpack/rspack so no reason why not to try it, especially since this allows for inlining entrypoints for faster startup (before webpack bailed out of this optimization because InitializeCore was used in other places)

Test plan

  • - testers work

Copy link

changeset-bot bot commented Jan 16, 2025

🦋 Changeset detected

Latest commit: 28cbdf4

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 4 packages
Name Type
@callstack/repack Major
@callstack/repack-plugin-reanimated Major
@callstack/repack-dev-server Major
@callstack/repack-init Major

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

vercel bot commented Jan 16, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
repack-website ⬜️ Ignored (Inspect) Jan 16, 2025 3:28pm

Copy link
Member

@thymikee thymikee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any measurable improvements?

@jbroma
Copy link
Member Author

jbroma commented Jan 16, 2025

Any measurable improvements?

measurable? maybe
noticeable? nope - but we would probably need to go to low-end android devices to see the benefit tbh

@jbroma jbroma changed the title feat: enable inlining entrypoints feat: enable inlining RN entrypoints Jan 16, 2025
@jbroma jbroma merged commit 0e600d4 into main Jan 16, 2025
5 checks passed
@jbroma jbroma deleted the feat/replace-private-initialize-core branch January 16, 2025 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants