-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
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
Vue SSR is not equal (isomorph) to its CSR with inline styles. Hydration not possible without re-rendering. #11211
Comments
This is because when style is set client side, through |
I think you closed this issue too fast. Have you seen the demo that Vue complains and is saying that it performs a full re-render? For real isomorphism it is expected to have the same output. I do not think this is solved. You kinda provided an "explanation" but it does not solve the issue. |
Also there is additional whitespace added. I get what you are saying. But this is by definition not isomorph to the |
I adapted the code example now so that the error from Vue is visible. Please re-open.
|
Okay so with the newest example provided in codesandbox Vue does not complain anymore. I would still recommend to reach 100% of isomorphism by recreating the browser behaviour SSR side. Is that an option? |
Version
2.6.11
Reproduction link
https://codesandbox.io/s/vue-csr-ssr-diff-github-issue-n0rbl
Steps to reproduce
What is expected?
It should output the EXACT same HTML to be isomorph. The only allowed difference must be
data-server-rendered="true"
attribute which only applies for SSR.It should output
XOR
What is actually happening?
As you can see it the HTML differs even though it is the exact same Vue instance that is rendered CSR and SSR:
(if you cannot see it: it adds whitespace in the inline CSS and in one it adds "px" units)
The text was updated successfully, but these errors were encountered: