-
Notifications
You must be signed in to change notification settings - Fork 27k
refactor(core): throw an error when hydration marker is missing from DOM #51170
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
Conversation
49748d2 to
04f37f0
Compare
604aa26 to
28367ca
Compare
josephperrott
left a comment
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.
LGTM
Reviewed-for: dev-infra
AndrewKushnir
left a comment
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.
@JeanMeche thanks for the changes, everything looks good! The code is in the right location, just left a few comments with proposed improvements. Thank you.
5d58766 to
ce1283a
Compare
AndrewKushnir
left a comment
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.
@JeanMeche thanks for addressing the feedback! 👍 I've left a final comment and we should be ready for the next steps: presubmit and merge.
4c9389c to
df3f675
Compare
josephperrott
left a comment
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.
LGTM
Reviewed-for: fw-security
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.
@JeanMeche thanks for addressing comments 👍 I did a final pass and added a couple more (all minor comments).
df3f675 to
ff1c380
Compare
AndrewKushnir
left a comment
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.
@JeanMeche thanks for the update 👍
AndrewKushnir
left a comment
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.
Reviewed-for: public-api
|
@JeanMeche it looks like there is a merge conflict with the main branch. Could you please rebase and resolve conflicts when you get a chance? Thank you. |
01d9c4d to
824e3c2
Compare
|
@AndrewKushnir One final group of reviewers and we're good 👍 |
jessicajaniuk
left a comment
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.
reviewed-for: public-api
|
Caretaker note: the presubmit is "green", the only outstanding thing is an extra review from the |
|
@JeanMeche This PR has a merge conflict with the patch branch. I'm merging it into just minor. Feel free to create a patch rebase if you want to land it in patch. |
|
This PR was merged into the repository by commit 0a38dc3. |
|
@JeanMeche it looks like this PR only made it into the main branch, which is targeting the next major. It'd be great to include this change into the upcoming v16.2.0. Could you please create a version of this PR targeting 16.2.x branch (and label is as "target: rc")? Thank you. |
|
@AndrewKushnir @dylhunn I made it available at #51276 |
…DOM (angular#51170) non-destructive hydration expects the DOM tree to have the same structure in both places. With this commit, the app will throw an error if comments are stripped out by the http server (eg by some CDNs).
|
@JeanMeche thanks a lot for creating a patch version of this PR! 👍 |
|
@JeanMeche please let me know if you want me to put together an error guide page for this error or if you get a chance to help (I think we have a lot of useful text in code comments, we can use them in the error guide). Without an error guide page, we'd only show an error code in prod mode (which is where the problem would happen). Thank you. |
|
@AndrewKushnir I've opened PR #51340 👍 |
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
…DOM (angular#51170) non-destructive hydration expects the DOM tree to have the same structure in both places. With this commit, the app will throw an error if comments are stripped out by the http server (eg by some CDNs). fixes angular#51160 PR Close angular#51170


Non-destructive hydration expects the DOM tree to have the same structure in both places. With this commit, the app will throw an error if comments are stripped out by the http server (eg by some CDNs).
fixes #51160
I'll create a dedicate doc for the error in a subsequent PR.
PR Type
What kind of change does this PR introduce?
Does this PR introduce a breaking change?