You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(docs): improve SEO metadata and sitemap - #29
Documentation pages previously had no canonical tags or sitemap, and their language alternates used relative URLs and stayed on the entry page during client-side navigation.
Configure the production origin and clean URLs to match Cloudflare Pages, then manage canonical and reciprocal English/Korean hreflang links through Rspress useHead. The local SEO plugin supplies language alternatives from matching routes within the same documentation version and generates sitemap.xml from document routes. robots.txt advertises the sitemap; the 404 page and public verification assets are excluded. Document the setup in docs/README.md.
The implementation uses the existing Rspress 2.0.23 public configuration, plugin, and runtime APIs without dependency changes. Built-in sitemap configuration starts in 2.1.0, so this version uses the routeGenerated and afterBuild hooks. extendPageData supplies custom runtime metadata at the top level, preserving it when Rspress loads compiled MDX frontmatter.
Validation
Formatting, lint, root/docs typechecks, and all 216 existing tests pass; commit hooks also pass.
Production build and manual HTML/XML inspection: all 28 English/Korean documents have exactly one canonical and two reciprocal language links, with no duplicate head tags. The sitemap contains exactly the same 28 unique canonical URLs.
Browser smoke checks in production preview and development mode: canonical and both language alternatives update after internal navigation.
The Google verification file is preserved, and 404/public assets are excluded from the sitemap.
References
Official version-pinned Plugin API and useHead documentation, cross-checked against the installed 2.0.23 types and implementation.
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
This PR includes no changesets
When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types
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
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.
Documentation pages previously had no canonical tags or sitemap, and their language alternates used relative URLs and stayed on the entry page during client-side navigation.
Configure the production origin and clean URLs to match Cloudflare Pages, then manage canonical and reciprocal English/Korean hreflang links through Rspress
useHead. The local SEO plugin supplies language alternatives from matching routes within the same documentation version and generatessitemap.xmlfrom document routes.robots.txtadvertises the sitemap; the 404 page and public verification assets are excluded. Document the setup indocs/README.md.The implementation uses the existing Rspress 2.0.23 public configuration, plugin, and runtime APIs without dependency changes. Built-in sitemap configuration starts in 2.1.0, so this version uses the
routeGeneratedandafterBuildhooks.extendPageDatasupplies custom runtime metadata at the top level, preserving it when Rspress loads compiled MDX frontmatter.Validation
References