feat(docs): SEO Phase 1 — sitemap, robots.txt, metadata and canonical URLs#23
Merged
Conversation
…URLs SEO Phase 1 critical improvements for @deessejs/errors documentation site: - Add sitemap.ts with image sitemap (all doc pages + OG images) - Add robots.ts (allow all, disallow /api/search and /llms.mdx) - Add homepage metadata: description, OpenGraph, Twitter Card - Add canonical URLs to all doc pages via generateMetadata - Fix OG image route slug handling (defensive slice, removes 'image.png' safely) - Add homepage OG image route at /og/home - Add siteUrl to shared.ts as single source of truth - Add sitemap discovery link to root layout <head> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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
SEO Phase 1 critical improvements for the
@deessejs/errorsdocumentation site. This PR addresses the most impactful missing SEO elements identified in the documentation audit.What changed
apps/web/src/app/sitemap.tsapps/web/src/app/robots.tsapps/web/src/app/(home)/page.tsxmetadataexport (description, OpenGraph, Twitter Card)apps/web/src/app/docs/[[...slug]]/page.tsxalternates.canonicalapps/web/src/app/layout.tsx<head>apps/web/src/app/og/docs/[...slug]/route.tsximage.png)apps/web/src/app/og/home/route.tsxapps/web/src/lib/shared.tssiteUrlas single source of truthTest plan
npm run dev→ visit/sitemap.xml— all doc pages + homepage presentnpm run dev→ visit/robots.txt— directives displayed correctly<meta name="description">,og:*,twitter:*,<link rel="canonical">present<link rel="canonical">present<link rel="sitemap">present/og/docs/error-factory/image.png— OG image renders correctly/og/home/image.png— homepage OG image renders correctlynpm run type-check— passes🤖 Generated with Claude Code