GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — Fix nodeName to UPPERCASE in insertStylesheetIntoRoot by sweetliquid · Pull Request #28255 · react/react Conversation
|
|
Hi @sweetliquid! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at [email protected]. Thanks! |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Comparing: 7039834...8b3cf21 Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: Expand to show
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
If there are any problems, please guide me. Thanks! |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
@gnoff seems legit, and if not could we add a test that would fail this? |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
56b1460 to
fca552b
Compare
|
@sweetliquid the nodeName check is a shortcut to avoid the attribute lookup on link tags since it will likely be slower than just reading the node name. You're right thought that this is currently non-functional. But let's just fix it to uppercase so we can avoid the attr read for the majority of tags we process this way |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
fca552b to
7c5c931
Compare
|
@gnoff I've added back the nodeName check and fix it to uppercase, thanks for your explanation~ |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
7c5c931 to
8b3cf21
Compare
|
This pull request has been automatically marked as stale. If this pull request is still relevant, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize reviewing it yet. Your contribution is very much appreciated. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
bump |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
## Summary <!-- Explain the **motivation** for making this change. What existing problem does the pull request solve? --> <img width="518" alt="image" src="https://github.com/facebook/react/assets/18693190/6d12df76-7dae-403b-b486-4940992abe8d"> The condition `node.nodeName === 'link'` is always `false`, because `node.nodeName` is Uppercase in specification. And the condition `node.nodeName === 'LINK'` is unnecessary, because Fizz hoists tags when it's `media` attribute is `"not all"`, whether it is a `link` or a `style` (line 36): https://github.com/facebook/react/blob/18cbcbf783377c5a22277a63ae41af54504502e0/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInstructionSetExternalRuntime.js#L30-L44 https://github.com/facebook/react/blob/18cbcbf783377c5a22277a63ae41af54504502e0/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInstructionSetInlineSource.js#L30-L44 DiffTrain build for [b75cc07](b75cc07)
**breaking change for canary users: Bumps peer dependency of React from `19.0.0-rc-206df66e-20240912` to `19.0.0-rc-a99d8e8d-20240916`** [diff react/react@206df66e...a99d8e8d](react/react@206df66...a99d8e8) <details> <summary>React upstream changes</summary> - react/react#30977 - react/react#30971 - react/react#30922 - react/react#30917 - react/react#30902 - react/react#30912 - react/react#30970 - react/react#30969 - react/react#30967 - react/react#30966 - react/react#30960 - react/react#30968 - react/react#30961 - react/react#28255 - react/react#30957 - react/react#30958 - react/react#30959 - react/react#30951 - react/react#30954 - react/react#30920 - react/react#30942 </details>
## Summary <!-- Explain the **motivation** for making this change. What existing problem does the pull request solve? --> <img width="518" alt="image" src="https://github.com/facebook/react/assets/18693190/6d12df76-7dae-403b-b486-4940992abe8d"> The condition `node.nodeName === 'link'` is always `false`, because `node.nodeName` is Uppercase in specification. And the condition `node.nodeName === 'LINK'` is unnecessary, because Fizz hoists tags when it's `media` attribute is `"not all"`, whether it is a `link` or a `style` (line 36): https://github.com/facebook/react/blob/18cbcbf783377c5a22277a63ae41af54504502e0/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInstructionSetExternalRuntime.js#L30-L44 https://github.com/facebook/react/blob/18cbcbf783377c5a22277a63ae41af54504502e0/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInstructionSetInlineSource.js#L30-L44
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.