react-native icon indicating copy to clipboard operation
react-native copied to clipboard

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

Open p-sun opened this issue 3 years ago • 2 comments

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

p-sun avatar Aug 27 '22 05:08 p-sun

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

facebook-github-bot avatar Aug 27 '22 05:08 facebook-github-bot

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: c8aafb322e89a0e4c25173de2cab2d6e9a085bfd Branch: main

analysis-bot avatar Aug 27 '22 05:08 analysis-bot

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

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

react-native-bot avatar Sep 09 '22 22:09 react-native-bot