Hydration Error at use teleport
See original GitHub issueEnvironment
- node: LTS
- nuxt: latest
Reproduction
https://codesandbox.io/s/nuxt3-teleport-bug-6b2vr
Describe the bug
Hello 😀
Hydration error occurs when using teleport in nuxt3. I inserted a teleport target in app.vue and it works normally until code movement. However, since hydration mismatch occurs, the function of the code to be teleported cannot operate normally.
Additional context
No response
Logs
[Vue warn]: Hydration children mismatch in <div>: server rendered element contains fewer child nodes than client vdom.
at <Example>
at <Index onVnodeUnmounted=fn<onVnodeUnmounted> ref=Ref<
undefined
> key="/" >
at <BaseTransition mode="out-in" appear=false persisted=false ... >
at <Transition name="page" mode="out-in" >
at <NuxtLayout key=0 name=undefined >
at <RouterView>
at <NuxtPage>
at <App>
at <Root>
Hydration completed but contains mismatches.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:4
- Comments:9 (4 by maintainers)
Top Results From Across the Web
react-hydration-error - Next.js
In general this issue is caused by using a specific library or application code that is relying on something that could differ between...
Read more >Server-Side Rendering (SSR) - Vue.js
An easier solution is to conditionally render the Teleport on mount. If you do need to hydrate teleported content, they are exposed under...
Read more >[Solved]-How to make `teleport` work in SSR in vue3?-Vue.js
To hydrate the teleport content, you need to use teleports property of the SSR context. Then, you need to inject them in the...
Read more >Teleport Community Edition Now Available in AWS ... - WDTN
Teleport is an identity-native infrastructure access platform for engineers and machines. By replacing insecure secrets with true identity, ...
Read more >Shadowmane - ARK: Survival Evolved Wiki - Fandom
If they find a target, they will chase after it, teleporting and shocking it. ... This information can be used to alter the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Has this problem been resolved?
I have also created a reproduction repository.
https://github.com/nixstrom/nuxt3-teleport-issue.git
I also created the same scenario in a “vanilla” Vue/Vue-router setup. This was working as expected; the issue only occurs for me when I add Nuxt3 to the mix.