-
Notifications
You must be signed in to change notification settings - Fork 17
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
Hydration issues: plugins, RTD, etc. #347
Comments
Both remix and next are moving to hydrating the whole document. It does look like there has been progress on this from the react core team, some of which is linked through here: ReadTheDocs hosting is very static html focused, and seems to be modifying the HTML on the way through, any changes to the body will cause hydration to fail and rerender when javascript is loaded as the html no longer matches the original server response (i.e. not the one RTD modified). That will remove any unexpected changes, regardless of the framework we use. I suspect a special readthedocs theme might be the way forward (or components), or configuring RTD to not change the HTML. |
Btw, the addition there is because I enabled the plugin for that, it can indeed be disabled. As for where to put it, I would say as a component, close to |
Closing this to focus the conversation on this issue: |
Describe the bug
context
Most context is in jupyter-book/mystmd#997.
Basically, hydration breakes browser plugins, RTD, etc. which try to inject additional elements in the html document
potential solution
One suggestion from the discussion is to move all content to an element inside the
html
document and hydrate that element instead of the whole document.Other consideration is does the hydration work the same in
next.js
, etc. or is it the same across allreact
environments? I.e. is it possible to hydrate only elements?Reproduce the bug
See console in https://mystmd-temp.readthedocs.io/latest/
The text was updated successfully, but these errors were encountered: