feat(app): serve a root-domain sitemap.xml - #550
Open
claude[bot] wants to merge 1 commit into
Open
claude[bot] wants to merge 1 commit into
claude[bot] wants to merge 1 commit into
Conversation
https://docs.page/sitemap.xml returned 404. Every hosted repo has its own generated sitemap, but nothing covered the root marketing site, so the root domain was invisible to sitemap-driven crawling. Adds a static App Router route serving a sitemap listing the root-level HTML pages that actually resolve (currently just the homepage), with cache policy via a new ROOT_SITEMAP_CACHE_HEADERS constant. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Y5HaatshAzKUdXWYUbAC4a
|
🚅 Deployed to the docs.page-pr-550 environment in docs.page
|
This was referenced Sep 8, 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.
Requested via Slack thread
One of five PRs replacing #530, which bundled all five root-domain discovery fixes into a single change.
Summary
Before:
https://docs.page/sitemap.xmlreturns a 404. Every repository hosted on docs.page gets its own generated sitemap under its own path, but nothing covers the docs.page root site, so a crawler that discovers pages through sitemaps finds nothing at all for the root domain.After: that same URL returns an XML sitemap listing the root-level pages that actually resolve — today that is just the homepage — served as
application/xmlwith a day-long edge TTL.In short: sitemap-driven crawlers get a real entry point for the root domain instead of a dead URL.
How: a new static App Router route at
app/src/app/sitemap.xml/route.tsholds the XML as a build-time constant, matching the shape of the per-repo sitemaps. Its cache policy comes from a newROOT_SITEMAP_CACHE_HEADERSconstant inapp/src/proxy.ts, using the same values as the existing root llms.txt route (day-long edge TTL, hourly browser revalidation).Scope
app/(hosted site, MCP, Ask AI)packages/cli/packages/mdx-bundler/docs/(product documentation)Type of change
Test plan
biome ci .clean (the check CI runs)bun test— 140 pass, 0 failtsc --noEmitinapp/— cleanNotes for reviewers
main, so this merges independently of the other four PRs.Sitemap:line pointing at this file, so merging this one first is the tidier order.🤖 Generated with Claude Code
https://claude.ai/code/session_01Y5HaatshAzKUdXWYUbAC4a
Generated by Claude Code