Commit c2c0e96
fix: use current location for canonical URL during SSR (#826)
The canonical path selector read from `state.resolvedLocation`, which
represents the previously resolved location and is undefined on the
initial SSR render. That made every server-rendered page fall back to
`/`, so blog posts (and every other route) emitted
`<link rel="canonical" href="https://tanstack.com/">`. Mobile share
sheets that honor the canonical then shared the root URL instead of the
actual post.
Switch to `state.location`, which is always populated with the current
requested location.
https://claude.ai/code/session_01UdssKwjy5SkB6gbB9y6XZS
Co-authored-by: Claude <noreply@anthropic.com>1 parent 4d6e400 commit c2c0e96
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
185 | 185 | | |
186 | 186 | | |
187 | 187 | | |
188 | | - | |
| 188 | + | |
189 | 189 | | |
190 | 190 | | |
191 | 191 | | |
| |||
0 commit comments