docs(start): fix broken routing-side guide link in authentication primitives (#7701)#7705
docs(start): fix broken routing-side guide link in authentication primitives (#7701)#7705EduardF1 wants to merge 1 commit into
Conversation
…mitives The "routing-side guide" links in the Authentication Server Primitives guide used a relative path (`../../../../router/guide/authenticated-routes.md`). While that resolves as a file path, it renders to an invalid site URL (`/start/latest/router/guide/authenticated-routes`) and 404s. Use the absolute cross-project doc path that the rest of the docs already use for Router links, e.g. `/router/latest/docs/framework/react/guide/authenticated-routes`. Closes TanStack#7701 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
📝 WalkthroughWalkthroughThe React authentication server primitives guide updates two links to the Router authenticated routes page under the ChangesDocumentation link refresh
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Possibly related issues
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@docs/start/framework/react/guide/authentication-server-primitives.md`:
- Line 6: The documentation link in the authentication server primitives guide
is using an absolute router URL instead of the required relative docs path.
Update the internal link in this markdown file to use a relative path from
docs/start/framework/react/guide/ to the authenticated routes doc under
docs/router/guide/, keeping the same link target but converting it to the
project’s relative-link format. Also make the same adjustment for the duplicated
reference noted in the comment.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: c87b9892-66e5-4ba7-881e-0c46adf03faf
📒 Files selected for processing (1)
docs/start/framework/react/guide/authentication-server-primitives.md
| --- | ||
|
|
||
| This guide covers the **server-side primitives** for building authentication in TanStack Start: session cookies, session lookup, OAuth, password-reset hardening, CSRF, and rate limiting. It pairs with the [routing-side guide](../../../../router/guide/authenticated-routes.md) (`_authenticated` layout, `beforeLoad`, redirects, RBAC). | ||
| This guide covers the **server-side primitives** for building authentication in TanStack Start: session cookies, session lookup, OAuth, password-reset hardening, CSRF, and rate limiting. It pairs with the [routing-side guide](/router/latest/docs/framework/react/guide/authenticated-routes) (`_authenticated` layout, `beforeLoad`, redirects, RBAC). |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Revert to relative links per coding guidelines.
Both updated links use an absolute /router/latest/... path, but the project coding guidelines require relative links to the docs/ folder format for all internal documentation. As per coding guidelines, docs/**/*.md files must use relative links to docs/ folder format (e.g., ./guide/data-loading) in internal documentation.
The destination file appears to live at docs/router/guide/authenticated-routes.md (per the supplied context snippet from docs/router/guide/authenticated-routes.md:1-8). The correct relative link from this file's location (docs/start/framework/react/guide/) should traverse to docs/router/guide/authenticated-routes.md.
🔗 Proposed relative link fix
-This guide covers the **server-side primitives** for building authentication in TanStack Start: session cookies, session lookup, OAuth, password-reset hardening, CSRF, and rate limiting. It pairs with the [routing-side guide](/router/latest/docs/framework/react/guide/authenticated-routes) (`_authenticated` layout, `beforeLoad`, redirects, RBAC).
+This guide covers the **server-side primitives** for building authentication in TanStack Start: session cookies, session lookup, OAuth, password-reset hardening, CSRF, and rate limiting. It pairs with the [routing-side guide](../../../router/guide/authenticated-routes.md) (`_authenticated` layout, `beforeLoad`, redirects, RBAC).-- [Authenticated Routes (Router)](/router/latest/docs/framework/react/guide/authenticated-routes) — the routing-side guide.
+- [Authenticated Routes (Router)](../../../router/guide/authenticated-routes.md) — the routing-side guide.Also applies to: 352-352
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@docs/start/framework/react/guide/authentication-server-primitives.md` at line
6, The documentation link in the authentication server primitives guide is using
an absolute router URL instead of the required relative docs path. Update the
internal link in this markdown file to use a relative path from
docs/start/framework/react/guide/ to the authenticated routes doc under
docs/router/guide/, keeping the same link target but converting it to the
project’s relative-link format. Also make the same adjustment for the duplicated
reference noted in the comment.
Source: Coding guidelines
|
On the CodeRabbit link-depth note: I left the absolute /router/latest/... links intentional for now. This docs area already uses absolute cross-package links, and the suggested relative path would resolve under docs/start/router/... from this file rather than the intended router docs root. Happy to switch if maintainers prefer all-relative links here, but I don't want to churn a working cross-package docs convention just to satisfy the bot. |
Summary
Fixes #7701.
The Authentication Server Primitives guide links to the routing-side
Authenticated Routesguide twice using a relative file path:[routing-side guide](../../../../router/guide/authenticated-routes.md)That path resolves as a file within the repo, but the docs site renders it to an invalid URL (
https://tanstack.com/start/latest/router/guide/authenticated-routes), which 404s — cross-project relative links don't map onto the site's/{project}/latest/docs/framework/react/...URL structure.Fix
Switch both links to the absolute cross-project doc path already used elsewhere in these docs for Router links (e.g.
[Router Authentication Guide](/router/latest/docs/framework/react/guide/authenticated-routes)inauthentication-overview.md):/router/latest/docs/framework/react/guide/authenticated-routesTwo occurrences updated (intro paragraph + "See Also" list). No content changes.
Validation
docs/router/guide/authenticated-routes.md→ site URL/router/latest/docs/framework/react/guide/authenticated-routes.authentication-overview.md,learn-the-basics.md).Not a duplicate
No open PR or other issue addresses #7701. Note:
isr.mdcontains one more link with the same broken relative pattern (../../../../router/guide/data-loading.md); left out to keep this PR scoped to the reported issue, happy to include it if maintainers prefer.Summary by CodeRabbit