Environment
Snapshot from Stackblitz
|
|
| Operating system |
Linux 5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/149.0.0.0 Safari/537.36 |
| CPU |
Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz (8 cores) |
| Node.js version |
v22.22.3 |
| nuxt/cli version |
3.36.0 |
| Package manager |
npm@10.8.2 |
| Nuxt version |
4.4.8 |
| Nitro version |
2.13.4 |
| Builder |
vite@7.3.5 |
| Config |
compatibilityDate, devtools, experimental, modules |
| Modules |
@nuxt/icon@2.2.3 |
Reproduction
https://stackblitz.com/edit/github-7lfrz9wc
Describe the bug
When using selective client rendering within Nuxt Island component (experimental.componentIslands.selectiveClient: true), any component that uses onServerPrefetch inside the tree marked to be hydrated on client side using nuxt-client attribute ends up not being rendered during SSR and causing hydration mismatch errors when hydrating on the client side.
This primarily affects Nuxt Icon, as it uses onServerPrefetch inside its NuxtIconCss
Additional context
No response
Logs
Environment
Snapshot from Stackblitz
Linux 5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/149.0.0.0 Safari/537.36Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz (8 cores)v22.22.33.36.0npm@10.8.24.4.82.13.4vite@7.3.5compatibilityDate,devtools,experimental,modules@nuxt/icon@2.2.3Reproduction
https://stackblitz.com/edit/github-7lfrz9wc
Describe the bug
When using selective client rendering within Nuxt Island component (
experimental.componentIslands.selectiveClient: true), any component that usesonServerPrefetchinside the tree marked to be hydrated on client side usingnuxt-clientattribute ends up not being rendered during SSR and causing hydration mismatch errors when hydrating on the client side.This primarily affects Nuxt Icon, as it uses
onServerPrefetchinside itsNuxtIconCssAdditional context
No response
Logs