No sitemap.xml, no robots.txt. Google can't efficiently discover review pages, and there's no way to signal Disallow: for admin / API paths. For a directory site, SEO is half the discoverability story.
Scope
- Generated
GET /sitemap.xmlaction that walksjudges,court_houses, and publishedjudge_reviews, emits proper<url><loc>...</loc><lastmod>...</lastmod></url>entries. Cache for 1 hour (regen on a cron or lazy refresh). - Static
public/robots.txt:User-agent: * Allow: / Disallow: /admin/ Disallow: /api/ Disallow: /settings Sitemap: https://<host>/sitemap.xml - Canonical URLs in every page head (
<link rel="canonical" ...>) so duplicate-path crawl doesn't dilute pagerank. - Optional but cheap: structured-data JSON-LD on article pages for
Reviewschema.org type.
Acceptance
- Google Search Console accepts the submitted sitemap without errors.
curl -I /robots.txtreturns 200 with the right content.- Admin / API paths don't appear in Google index queries (
site:<host>).
Files to touch
app/Actions/SitemapAction.ts— newroutes/api.ts(orroutes/web.ts) — route registrationpublic/robots.txt(or layout if generated)