-
-
Notifications
You must be signed in to change notification settings - Fork 19
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
DOM changes from client-side JS are wiped away on refresh #7
Comments
Oh, yeah—hmm. Couple of ideas here:
|
|
Going to close this one per the |
Thinking further about this, I’m wondering if there’s a way to scope the changes. It would definitely increase complexity, but you could theoretically compare the .html file both before and after the rebuild, then only update the nodes that have actually changed. Not really sure it’s worth developing what amounts to a frontend framework for this though 😉 |
I’m not sure what the best solution to this would be, but it can be pretty disruptive to have DOM modifications — especially those automatically applied on page load — get wiped away.
For example, Bootstrap dropdowns are closed and HTML attributes added to top-level tags like
html
andbody
are wiped away.Since
load
andDOMContentLoaded
handlers are not called again (and scripts are not re-run), the page can easily get into a bad state.The text was updated successfully, but these errors were encountered: