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

Modularlize RCTBridgeModule.h 2/n - Move RCTTurboModuleRegistry.h to its own file in ReactInternal target #34514

Closed
wants to merge 1 commit into from

Conversation

p-sun
Copy link
Contributor

@p-sun p-sun commented Aug 27, 2022

Summary:
Changelog: [Internal][iOS] Modularlize RCTBridgeModule.h 1/n - Move RCTTurboModuleRegistry.h to its own file in ReactInternal target

Why clean up RCTBridgeModule.h?

Clean up one unnecessary import of RCTBridgeModule.h.

RCTBridgeModule includes a lot of header files, and this header is imported everywhere. The ultimate goal is that files (especially React Native infra files) should only import only what they need and not import the entirely of RCTBridgeModule.h whenever possible.

This way, certain headers that are Bridge-only can be compiled out of the new architecture with a flag.

Differential Revision: D38971168

…its own file in ReactInternal target

Summary:
Changelog: [Internal][iOS] Modularlize RCTBridgeModule.h 1/n -  Move RCTTurboModuleRegistry.h to its own file in ReactInternal target

# Why clean up RCTBridgeModule.h?
Clean up one unnecessary import of RCTBridgeModule.h.

RCTBridgeModule includes a lot of header files, and this header is imported everywhere. The ultimate goal is that files (especially React Native infra files) should only import only what they need and not import the entirely of RCTBridgeModule.h whenever possible.

This way, certain headers that are Bridge-only can be compiled out of the new architecture with a flag.

Differential Revision: D38971168

fbshipit-source-id: 413fc098e2201e601df739f38d006562295fc3a7
@p-sun p-sun requested a review from mhorowitz as a code owner August 27, 2022 05:33
@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner fb-exported labels Aug 27, 2022
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D38971168

@analysis-bot
Copy link

Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 7,617,818 -54
android hermes armeabi-v7a 7,032,047 -72
android hermes x86 7,917,890 -41
android hermes x86_64 7,891,518 -30
android jsc arm64-v8a 9,495,229 -54
android jsc armeabi-v7a 8,272,846 -68
android jsc x86 9,433,036 -38
android jsc x86_64 10,026,026 -38

Base commit: c8aafb3
Branch: main

@react-native-bot
Copy link
Collaborator

This pull request was successfully merged by @p-sun in 4e70376.

When will my fix make it into a release? | Upcoming Releases

@react-native-bot react-native-bot added the Merged This PR has been merged. label Sep 9, 2022
OlimpiaZurek pushed a commit to OlimpiaZurek/react-native that referenced this pull request May 22, 2023
…its own file in ReactInternal target (facebook#34514)

Summary:
Pull Request resolved: facebook#34514

Changelog: [Internal][iOS] Modularlize RCTBridgeModule.h 3/n -  Move RCTTurboModuleRegistry.h to its own file in ReactInternal target

# Why clean up RCTBridgeModule.h?
Clean up one unnecessary import of RCTBridgeModule.h.

RCTBridgeModule includes a lot of header files, and this header is imported everywhere. The ultimate goal is that files (especially React Native infra files) should only import only what they need and not import the entirety of RCTBridgeModule.h whenever possible.

This way, certain headers that are Bridge-only can be compiled out of the new architecture with a flag.

Reviewed By: RSNara

Differential Revision: D38971168

fbshipit-source-id: 3b1b23d422f965a5a14bc4178d32b844906f2c8b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants