Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

🐛 v-html Breaks SSR on Page Refresh - Hydration Mismatch #13279

Unanswered
Zisan-uzum asked this question in Q&A
Discussion options

Using v-html in Nuxt components causes hydration mismatches that break pages when refreshed. The issue occurs because:
Server-Side: Nuxt renders static HTML during SSR
Client-Side: Vue processes v-html and potentially changes DOM structure
Mismatch: Vue detects differences and discards server HTML, causing content to break

- Defeats SSR purpose, bad for SEO

  1. Is there a native Vue/Nuxt solution for safe HTML rendering in SSR?
  2. Should v-html behavior be consistent between server and client?
You must be logged in to vote

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

I had the same issue a few weeks ago and actually stopped working on that for a while. I’ll follow this discussion to see any updates or insights.

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /