-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Production build failure of svelte@5.0.0-next.179 -> svelte@5.0.0-next.182 #12422
Comments
I want to highlight, this problem doesn't occur in dev, only in prod builds. |
I'm not able to reproduce this given the code snippet. Please provide a reproduction repository. |
https://replit.com/@yodaissmart/500-next182-prod-issue?v=1 In the shell run |
I should probably have noted this is while in use with conjunction with the latest version of sveltekit, and given it occurs when hydrating its probably sveltekit failing, but the failure is specific to the version of svelte. As noted, it doesn't occur in |
We've marked several methods used for walking the DOM with a `__NO_SIDE_EFFECTS__` comment. That was good historically, because we didn't need those kept around if its results were unused, but since the hydration changes in #12335 this actually introduces a bug: Because that PR now relies on the hydration nodes being correct due to walking the DOM, tree-shaking unused variables/calls results in the walk being incorrect, leading to bugs Fixes #12422
We've marked several methods used for walking the DOM with a `__NO_SIDE_EFFECTS__` comment. That was good historically, because we didn't need those kept around if its results were unused, but since the hydration changes in #12335 this actually introduces a bug: Because that PR now relies on the hydration nodes being correct due to walking the DOM, tree-shaking unused variables/calls results in the walk being incorrect, leading to bugs Fixes #12422
We've marked several methods used for walking the DOM with a `__NO_SIDE_EFFECTS__` comment. That was good historically, because we didn't need those kept around if its results were unused, but since the hydration changes in #12335 this actually introduces a bug: Because that PR now relies on the hydration nodes being correct due to walking the DOM, tree-shaking unused variables/calls results in the walk being incorrect, leading to bugs Fixes #12422
We've marked several methods used for walking the DOM with a `__NO_SIDE_EFFECTS__` comment. That was good historically, because we didn't need those kept around if its results were unused, but since the hydration changes in #12335 this actually introduces a bug: Because that PR now relies on the hydration nodes being correct due to walking the DOM, tree-shaking unused variables/calls results in the walk being incorrect, leading to bugs Fixes #12422
Describe the bug
In production only svelte is attempting to append a child to a text node during hydration. This causes JS to hard crash and the page to fail.
This bug did not occur in svelte@5.0.0-next.178
Reproduction
The component where this occurs is a simple breadcrumb component
changing the component so the children of the each block are all on one line fixes this issue.
E.G.
But it shouldn't be attempting to append a child to a text node.
Logs
System Info
Severity
annoyance
The text was updated successfully, but these errors were encountered: