Vue · Senior · Question 55 of 75
What does data-allow-mismatch (Vue 3.5+) do?
<span data-allow-mismatch="text">{{ new Date().toLocaleString() }}</span>- ✓Correct answer: Suppresses hydration mismatch warnings for an expected client/server difference
- 2Forces client-only rendering of the element
- 3Disables hydration for the whole app
Explanation
Use it for unavoidable differences like dates. It hides the warning but doesn't fix it, so keep its use narrow.