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
{{ message }}
This repository was archived by the owner on Jan 11, 2023. It is now read-only.
Is your feature request related to a problem? Please describe.
Maybe I'm not doing this correctly but when I bind a value to a form input (first load, page rendered by ssr) and change the HTML input value before client-side rehydration takes place, my changes are lost. The rehydration resets my value to ssr'ed value.
I did not recognize this when browsing my site normally. I recognized it (took me a while to figure out) when using Cypress to run automated in-browser tests. Since Cypress uses browser hooks, it manages to emit input events into the HTML form control BEFORE Sapper rehydration takes place (which is fast enough that a normal user might not notice).
Describe the solution you'd like
Angular Universal solves this problem by introducing https://github.com/angular/preboot, which basically casts an overlay on the entire window, capturing all input events, and pass them through to your application once it completely loads.
How important is this feature to you?
Like I said, since rehydration is fast enough, normal users proabbly won't see the problems. However, autofill may not work correctly (such as LastPass go to site + autofill login form feature).
It's a logic gap that I would love to see properly bridged anyway.
The text was updated successfully, but these errors were encountered:
The problem, I guess, is two-fold. So it is not exactly a duplicate.
ONE: Per #911, server-rendered HTML elements are discarded then recreated under certain circumstances. Changes made to these elements before that happens will also be discarded => true.
But also TWO: Even if the elements are NOT discarded / recreated, if input events are emitted from the elements before client-side Svelte gets a chance to attach its listeners, these input events are missed too.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Is your feature request related to a problem? Please describe.
Maybe I'm not doing this correctly but when I bind a value to a form input (first load, page rendered by ssr) and change the HTML input value before client-side rehydration takes place, my changes are lost. The rehydration resets my value to ssr'ed value.
I did not recognize this when browsing my site normally. I recognized it (took me a while to figure out) when using Cypress to run automated in-browser tests. Since Cypress uses browser hooks, it manages to emit input events into the HTML form control BEFORE Sapper rehydration takes place (which is fast enough that a normal user might not notice).
Describe the solution you'd like
Angular Universal solves this problem by introducing https://github.com/angular/preboot, which basically casts an overlay on the entire window, capturing all input events, and pass them through to your application once it completely loads.
How important is this feature to you?
Like I said, since rehydration is fast enough, normal users proabbly won't see the problems. However, autofill may not work correctly (such as LastPass go to site + autofill login form feature).
It's a logic gap that I would love to see properly bridged anyway.
The text was updated successfully, but these errors were encountered: