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

isFBBundle should be true if it's FB for www or FB for RN #19420

Merged
merged 1 commit into from
Jul 20, 2020

Conversation

sebmarkbage
Copy link
Collaborator

This ensures that the .fb.js override files kick in for RN. Otherwise we won't have FB specific exports in the isomorphic modules.

@sebmarkbage sebmarkbage requested a review from rickhanlonii July 20, 2020 17:21
@facebook-github-bot facebook-github-bot added CLA Signed React Core Team Opened by a member of the React Core Team labels Jul 20, 2020
@@ -357,7 +357,7 @@ function getPlugins(
bundleType === RN_FB_DEV ||
bundleType === RN_FB_PROD ||
bundleType === RN_FB_PROFILING;
const shouldStayReadable = isFBBundle || isRNBundle || forcePrettyOutput;
const shouldStayReadable = isFBWWWBundle || isRNBundle || forcePrettyOutput;
Copy link
Collaborator Author

@sebmarkbage sebmarkbage Jul 20, 2020

Choose a reason for hiding this comment

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

Arguably shouldStayReadable should be false for OSS RN since we don't trust the minifier.

This ensures that the .fb.js override files kick in for RN. Otherwise we
won't have FB specific exports in the isomorphic modules.
@codesandbox-ci
Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 3960bc6:

Sandbox Source
React Configuration

@sizebot
Copy link

sizebot commented Jul 20, 2020

Details of bundled changes.

Comparing: b23ea02...3960bc6

react

File Filesize Diff Gzip Diff Prev Size Current Size Prev Gzip Current Gzip ENV
react-jsx-runtime.development.js 0.0% 0.0% 37.4 KB 37.4 KB 10.76 KB 10.76 KB NODE_DEV
react.development.js 0.0% 0.0% 108.96 KB 108.96 KB 26.59 KB 26.59 KB UMD_DEV
react-jsx-runtime.production.min.js 0.0% 🔺+0.3% 971 B 971 B 605 B 607 B NODE_PROD
React-dev.js +34.0% +22.9% 73.16 KB 98.01 KB 19.38 KB 23.81 KB RN_FB_DEV
React-prod.js 🔺+29.9% 🔺+21.6% 13.83 KB 17.96 KB 3.92 KB 4.77 KB RN_FB_PROD
React-profiling.js +29.9% +21.6% 13.83 KB 17.96 KB 3.92 KB 4.77 KB RN_FB_PROFILING
react-jsx-dev-runtime.development.js 0.0% 0.0% 36.81 KB 36.81 KB 10.58 KB 10.58 KB NODE_DEV
react-jsx-dev-runtime.production.min.js 0.0% 🔺+0.3% 465 B 465 B 321 B 322 B NODE_PROD
react-jsx-dev-runtime.profiling.min.js 0.0% +0.3% 464 B 464 B 321 B 322 B NODE_PROFILING
react.production.min.js 0.0% 0.0% 11.39 KB 11.39 KB 4.54 KB 4.55 KB UMD_PROD
react-jsx-runtime.profiling.min.js 0.0% +0.3% 970 B 970 B 605 B 607 B NODE_PROFILING
react.profiling.min.js 0.0% 0.0% 14.9 KB 14.9 KB 5.63 KB 5.63 KB UMD_PROFILING
react.development.js 0.0% 0.0% 70.4 KB 70.4 KB 18.96 KB 18.97 KB NODE_DEV
react.production.min.js 0.0% 0.0% 6.33 KB 6.33 KB 2.62 KB 2.62 KB NODE_PROD
React-dev.js 0.0% 0.0% 99.18 KB 99.18 KB 24.05 KB 24.05 KB FB_WWW_DEV
React-prod.js 0.0% 0.0% 17.71 KB 17.71 KB 4.61 KB 4.61 KB FB_WWW_PROD
React-profiling.js 0.0% 0.0% 17.71 KB 17.71 KB 4.61 KB 4.61 KB FB_WWW_PROFILING

React: size: 0.0%, gzip: 0.0%

Size changes (stable)

Generated by 🚫 dangerJS against 3960bc6

@sizebot
Copy link

sizebot commented Jul 20, 2020

Details of bundled changes.

Comparing: b23ea02...3960bc6

react

File Filesize Diff Gzip Diff Prev Size Current Size Prev Gzip Current Gzip ENV
react-jsx-runtime.development.js 0.0% 0.0% 37.41 KB 37.41 KB 10.76 KB 10.76 KB NODE_DEV
react.development.js 0.0% 0.0% 112.99 KB 112.99 KB 27.36 KB 27.36 KB UMD_DEV
react-jsx-runtime.production.min.js 0.0% 🔺+0.3% 984 B 984 B 613 B 615 B NODE_PROD
react-unstable-cache.development.js 0.0% +0.3% 1.05 KB 1.05 KB 586 B 588 B NODE_DEV
React-dev.js +25.7% +17.2% 77.17 KB 97.02 KB 20.11 KB 23.58 KB RN_FB_DEV
react-unstable-cache.production.min.js 0.0% 🔺+0.2% 867 B 867 B 562 B 563 B NODE_PROD
React-prod.js 🔺+12.7% 🔺+7.8% 15.81 KB 17.82 KB 4.39 KB 4.73 KB RN_FB_PROD
react-unstable-cache.profiling.min.js 0.0% +0.2% 866 B 866 B 561 B 562 B NODE_PROFILING
React-profiling.js +12.7% +7.8% 15.81 KB 17.82 KB 4.39 KB 4.73 KB RN_FB_PROFILING
react-jsx-dev-runtime.development.js 0.0% 0.0% 36.83 KB 36.83 KB 10.58 KB 10.59 KB NODE_DEV
react-jsx-dev-runtime.production.min.js 0.0% 🔺+0.3% 478 B 478 B 330 B 331 B NODE_PROD
react-jsx-dev-runtime.profiling.min.js 0.0% +0.3% 477 B 477 B 330 B 331 B NODE_PROFILING
react.production.min.js 0.0% 0.0% 12.5 KB 12.5 KB 4.88 KB 4.88 KB UMD_PROD
react-jsx-runtime.profiling.min.js 0.0% +0.2% 983 B 983 B 613 B 614 B NODE_PROFILING
react.profiling.min.js 0.0% 0.0% 16.04 KB 16.04 KB 5.97 KB 5.98 KB UMD_PROFILING
react.development.js 0.0% 0.0% 74.24 KB 74.24 KB 19.68 KB 19.69 KB NODE_DEV
react.production.min.js 0.0% 🔺+0.1% 7.5 KB 7.5 KB 2.96 KB 2.96 KB NODE_PROD
React-dev.js 0.0% 0.0% 98.18 KB 98.18 KB 23.85 KB 23.86 KB FB_WWW_DEV
React-prod.js 0.0% 0.0% 17.57 KB 17.57 KB 4.57 KB 4.57 KB FB_WWW_PROD
React-profiling.js 0.0% 0.0% 17.57 KB 17.57 KB 4.57 KB 4.57 KB FB_WWW_PROFILING

React: size: 0.0%, gzip: 0.0%

Size changes (experimental)

Generated by 🚫 dangerJS against 3960bc6

Copy link
Member

@rickhanlonii rickhanlonii left a comment

Choose a reason for hiding this comment

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

LGTM

@sebmarkbage sebmarkbage merged commit ab1f517 into facebook:master Jul 20, 2020
@0xdevalias 0xdevalias mentioned this pull request Jul 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed React Core Team Opened by a member of the React Core Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants