You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: ensure custom element updates don't run in hydration mode (#15217)
* fix: ensure custom element updates don't run in hydration mode
When a custom element is created before Svelte hydration kicks in, it will scaffold itself, using the properties given via attributes.
Now when a custom element property is set during Svelte's hydration, the Svelte custom element component could run logic like updating an each block. Without turning off hydration mode during that time, the update would try to pick up existing element nodes (because it thinks they must be there because of hydration mode), and crash.
No test because it would require a setup where we can ensure the element is scaffolded before hydration runs.
Fixes#15213
* changeset
---------
Co-authored-by: Rich Harris <[email protected]>
0 commit comments