Hydration Issue causes Duplicate HEAD Script
See: https://github.com/TanStack/router/issues/4585
I don’t have a shareable example, I can try to reproduce into an isolated repo over the weekend, however.
What is happening: SSR is filling in LD-JSON data in the HEAD of my page route with SEO specific metadata for Google to render with the results (e.g a star review rating for the page)
When Google bot loads the page, there is a hydration issue, and when the client resolves the hydration mismatch, the HEAD gets loaded again, causing TWO LD-JSON script tags on the page.
This is then causing Googlebot to issue validation errors on my page and disables the enrichments
I don’t have a shareable example, I can try to reproduce into an isolated repo over the weekend, however.
What is happening: SSR is filling in LD-JSON data in the HEAD of my page route with SEO specific metadata for Google to render with the results (e.g a star review rating for the page)
When Google bot loads the page, there is a hydration issue, and when the client resolves the hydration mismatch, the HEAD gets loaded again, causing TWO LD-JSON script tags on the page.
This is then causing Googlebot to issue validation errors on my page and disables the enrichments
GitHub
Which project does this relate to? Start Describe the bug When using the Scripts component and defining scripts array inside createRootRoute, the same script gets added multiple times in the head t...