feat(seo): add robots.txt and sitemap.xml - #1085
Open
mdo wants to merge 1 commit into
Open
Conversation
Neither production site served a robots.txt or sitemap.xml (both 404, or shadowed by the diffshub catch-all before its 404 fix). Adds Next.js robots.ts and sitemap.ts to both apps. The docs sitemap is site-aware (8 diffs routes or 10 trees routes, chosen by NEXT_PUBLIC_SITE); diffshub lists only the home page since the viewer path space is unbounded and noindex. A shared lib/site-origin centralizes the origin used by robots, sitemap, and canonical URLs.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
2 tasks
necolas
approved these changes
Aug 19, 2026
This was referenced Aug 19, 2026
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
robots.txtorsitemap.xml(both 404 on diffs.com / trees.software; shadowed on diffshub.com until the 404 fix in the base PR). Search engines got no crawl guidance and no URL inventory.robots.ts+sitemap.tsto both apps.NEXT_PUBLIC_SITE(the other product's routes callnotFound(), so advertising both would point crawlers at guaranteed 404s). DiffsHub lists only the home page.apps/docs/lib/site-origin.tscentralizes the origin shared by robots, sitemap, and (in the next PR) canonicals.Test plan
/robots.txtreturns a valid file pointing at/sitemap.xmlon both apps/sitemap.xmllists the correct route set per sitemoonx docs:typecheckandmoonx diffshub:typecheckStacked on #1084 (2 of 4).