feat(docs): improve SEO across docs site#1561
Open
nicolai-rhesis wants to merge 2 commits intomainfrom
Open
Conversation
- Fix robots meta to respect ROBOTS_NOINDEX env var on all MDX routes - Fix sitemap lastModified to use real file mtimes instead of new Date() - Support page-level keywords in frontmatter merged with sitewide defaults - Add explicit title/description/keywords frontmatter to top 10 pages: docs/index, getting-started, connecting-application, concepts, tracing, endpoints, test-execution, guides/index, sdk/installation, sdk/client
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.
Purpose
Address SEO issues found during an audit of the docs site.
What Changed
Bug fixes
generatePageMetadatapreviously hardcodedrobots: { index: true }on every MDX page, ignoring theROBOTS_NOINDEXenv var used by the root layout. Staging/preview deployments are now correctly noindexed.lastModified— was alwaysnew Date()(today). Now uses real filemtimeviafs.statSync, so crawlers only re-fetch pages that actually changed.Enhancements
generatePageMetadatanow readskeywordsfrom MDX frontmatter and merges them with the sitewide defaults (deduplicated). Previously every page had identical keywords.title,description, andkeywordsto the highest-traffic pages so search snippets are controlled rather than auto-extracted:docs/index(Welcome)docs/getting-starteddocs/getting-started/connecting-applicationdocs/conceptsdocs/tracingdocs/endpointsdocs/test-executionguides/indexsdk/installationsdk/clientTesting
<head>to verify correct<title>,<meta name="description">, and<meta name="keywords">