fix: resolve docs SEO link and redirect issues#960
Draft
teallarson wants to merge 3 commits intomainfrom
Draft
Conversation
- D-1: Add 163 locale-less sibling redirect rules to next.config.ts so locale-less inbound URLs (e.g. /home/auth/X) resolve in one hop instead of two (middleware locale-detection + path-restructure rule) - D-2: Rewrite internal MDX links to include /en/ locale prefix across 111 pages, eliminating 3,700+ redirect hits Ahrefs attributed to docs - D-3: Fix 383 broken-link rows — remove clickable Resources breadcrumb in toolkit pages (href="/en/resources" was 404), add redirect rules for 13 removed/renamed pages (squareup→square, home/*, toolkit pages) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…prefix The proxy.ts (renamed from middleware.ts in #752a7b54) already adds the /en/ prefix for locale-less requests. The 163 sibling rules were duplicating that work to save one hop on external inbound links. Trade-off accepted: 47 redirect chains stay 2-hop (proxy + restructure), but the diff shrinks by ~900 lines and the multi-locale story stays honest (proxy can grow Accept-Language detection later without a hardcoded /en/ destination in 163 places). Also fix collateral damage: D-2's MDX bulk rewrite mangled image paths ( → ) — revert image-syntax matches back to /images/. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR cleans up docs links and redirects reported by an Ahrefs SEO audit, using plain route fixes instead of audit-code shorthand.
/en/locale prefix, so crawlers and users avoid unnecessary redirect hops from locale-less URLs./images/..., andllms.txtlinks remain/llms.txt.Resourcesas plain breadcrumb text instead of linking to/en/resources, which does not exist./home/*pages,squareuptosquare, removed toolkit pages, the old Daytona overview path, and the old nested Gmail toolkit path.next.config.tsbecauseproxy.tsalready adds the locale prefix. That keeps the redirect config smaller and avoids hardcoding/en/in places that would need to change if additional locales become active.Validation
pnpm buildpasses locally.lint-stagedand Ultracite)./en/resources/integrations/development/githubshowResourcesas breadcrumb text, not a broken link.Expected SEO impact
Page has links to redirectrows after the/en/internal-link rewrite.Page has links to broken pagerows after the breadcrumb fix and redirect additions. The remaining Cloudflare email-obfuscation rows are intentional.