-
Notifications
You must be signed in to change notification settings - Fork 47k
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
Fix and update attribute-behavior fixture #26114
Conversation
Comparing: 55542bc...dfb5f26 Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) |
@eps1lon once #26106 lands the meta tags will get hoisted but won't require the extra props to avoid getting dropped. do you want to wait for that to land this or undo these changes once that one is incorporated? Also is this running on oss-stable only? It seems it is not flagged but we could in theory have singletons and hoistables on for some builds and not others |
I think it's better to wait for #26106 for now.
It's running on the published latest and on |
Ran without `<meta>` tags which currently crash the fixture
1adecbe
to
5f9e4ff
Compare
`version` is obsolete so I was hoping this result doesn't matter. But `lang` has the same behavior i.e. isn't added to the DOM on the client
96dd1bf
to
9a2f7f7
Compare
@@ -282,12 +284,12 @@ function getRenderedAttributeValue( | |||
try { | |||
let container = createContainer(); | |||
renderer.render(react.createElement(tagName, baseProps), container); | |||
defaultValue = read(container.firstChild); | |||
defaultValue = read(container.lastChild); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consistent with how we read the value of server-rendered markup. firstChild
returns the DOCTYPE now if we render into a document
on the client.
@@ -764,7 +772,7 @@ class App extends React.Component { | |||
ReactDOMStable: | |||
'https://unpkg.com/react-dom@latest/umd/react-dom.development.js', | |||
ReactDOMServerStable: | |||
'https://unpkg.com/react-dom@latest/umd/react-dom-server.browser.development.js', | |||
'https://unpkg.com/react-dom@latest/umd/react-dom-server-legacy.browser.development.js', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What caused this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
renderToString
is no longer included in react-dom-server.browser
. Makes sense considering renderToString
is considered legacy. renderToString
was already excluded from the 18.0.0 UMD bundle so there was no change to the UMD bundle in a SemVer minor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh odd, I thought that was already the case. sounds good
## Summary Due to #25928 the attribute fixture could no longer finish since it expects at least something to render. But since Fizz currently breaks down completely on malformed `<meta>` tags, the fixture could no longer handle this. The fixture now renders valid types for `meta` tags. Note that the snapshot change to `viewTarget`` is already on `main`. Review by commit helps to understand this. Added `html[lang]` so that we test at least one standard attribute on `<html>`. `version` is obsolete so results are not that trustworthy. ## How did you test this change? With Chrome Version 109.0.5414.119 (Official Build) (64-bit) - `yarn build --type=UMD_DEV react/index,react-dom && cd fixtures/attribute-behavior && yarn install && yarn start` DiffTrain build for [b8ae89f](b8ae89f) [View git log for this commit](https://github.com/facebook/react/commits/b8ae89f38288bfae37dff54fa1ec4bf3b4555ed5)
Summary
Due to #25928 the attribute fixture could no longer finish since it expects at least something to render. But since Fizz currently breaks down completely on malformed
<meta>
tags, the fixture could no longer handle this.The fixture now renders valid types for
meta
tags.Note that the snapshot change to
viewTarget`` is already on
main`. Review by commit helps to understand this.Added
html[lang]
so that we test at least one standard attribute on<html>
.version
is obsolete so results are not that trustworthy.How did you test this change?
With Chrome Version 109.0.5414.119 (Official Build) (64-bit)
yarn build --type=UMD_DEV react/index,react-dom && cd fixtures/attribute-behavior && yarn install && yarn start