You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using PrimeVue in a Nuxt application with the Nuxt module, the Galleria component does have a hydration mismatch.
A quick fix is to add :id="useId()" to the <Galleria> component.
I've had a look into the internals of PrimeVue and it seems like useId from Vue is already used, so I'm not really sure why the quick fix above works.
I've also tried some other components of PrimeVue, they didn't seem to have problems with hydration, but that was just kind of a smoke test since I don't have the time to test all components.
Describe the bug
When using PrimeVue in a Nuxt application with the Nuxt module, the Galleria component does have a hydration mismatch.
A quick fix is to add
:id="useId()"
to the<Galleria>
component.I've had a look into the internals of PrimeVue and it seems like
useId
from Vue is already used, so I'm not really sure why the quick fix above works.I've also tried some other components of PrimeVue, they didn't seem to have problems with hydration, but that was just kind of a smoke test since I don't have the time to test all components.
Pull Request Link
No response
Reason for not contributing a PR
Other Reason
No response
Reproducer
https://stackblitz.com/edit/primevue-galleria-hydration-mismatch?file=app%2Fcomponents%2FMyGalleria.vue
Environment
Vue & Nuxt in the newest version with PrimeVue and it's Nuxt module in the newest version
Vue version
3.5.13
PrimeVue version
4.2.5
Node version
No response
Browser(s)
No response
Steps to reproduce the behavior
Expected behavior
There should not be a hydration mismatch
The text was updated successfully, but these errors were encountered: