Skip to content

Restructure docs IA and improve SEO fundamentals#653

Open
ryanycoleman wants to merge 6 commits intostrands-agents:mainfrom
ryanycoleman:ia_redesign
Open

Restructure docs IA and improve SEO fundamentals#653
ryanycoleman wants to merge 6 commits intostrands-agents:mainfrom
ryanycoleman:ia_redesign

Conversation

@ryanycoleman
Copy link
Member

Description

  • Information architecture restructure — Consolidate navbar from 9 tabs to 6 by folding Labs and Contribute under Community. Promote Model Providers and Deploy to top-level sidebar sections for
    better discoverability. Reorder "Get Started" and "Build" sections to lead with tasks.
  • SEO meta optimization — Optimize homepage title/description for search intent. Add unique meta descriptions to top 20 docs pages (previously all used the same generic fallback).
  • Structured data (JSON-LD) — Add Organization (with AWS as parent), SoftwareApplication, and BreadcrumbList schema to all pages. Add WebSite with SearchAction on homepage.
  • Social/OG tags — Add og:image, twitter:card, and twitter:image site-wide. Create branded 1200x630 social preview image.
  • Sitemap improvements — Add git-based dates to XML sitemap entries.

Test plan

  • Verify homepage meta tags in view-source (<title>, , OG tags)
  • Spot-check a docs page for unique description and JSON-LD breadcrumbs
  • Validate JSON-LD with https://validator.schema.org/
  • Verify navigation structure renders correctly (6 navbar tabs, sidebar sections)
  • Confirm og-image.png loads at /og-image.png

Checklist

  • [X ] I have read the CONTRIBUTING document
  • [X ] My changes follow the project's documentation style
  • [X ] I have tested the documentation locally using npm run dev
  • [X ] Links in the documentation are valid and working

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

ryanycoleman and others added 4 commits March 12, 2026 10:51
Nav tabs reduced from 9 to 5: merged Labs and Contribute into
Community, merged Python API and TypeScript API into a single API
Reference tab with a sidebar language switcher, renamed User Guide
to Docs. Blog tab will be added by a separate PR.

Sidebar reorganized with a new task-first "Build" section (Adding
Tools, Using MCP Tools, Multi-Agent Systems, Streaming Responses,
Voice & Realtime, etc.) positioned above Concepts. Deploy promoted
from last to after Model Providers.

Homepage CTA now links directly to the Python quickstart, skipping
the overview routing page.

New "Why Strands?" page with model-driven vs workflow-driven
comparison, code examples, and a Python/TypeScript feature matrix.
Initial draft — content needs refinement.

Sidebar labels now sourced from navigation.yml rather than page
frontmatter, so nav labels can differ from page titles without
touching individual content files.
The XML sitemap previously had bare <loc> entries with no freshness
signal. Search engines and AI crawlers use <lastmod> to prioritize
recently updated content — without it, all pages appear equally
stale.

This adds a small Astro integration that runs a single git log
command at build time to collect the last commit date for each
content file, then injects those dates into the sitemap via the
@astrojs/sitemap serialize callback. Generated API reference pages
are skipped since they aren't git-tracked.

Result: 143 of 401 sitemap URLs now include <lastmod> dates.
The remainder are auto-generated API docs whose freshness is
better signaled by SDK version numbers.
… tags

- Optimize homepage title and meta description for search intent
- Add unique meta descriptions to top 20 documentation pages
- Add JSON-LD structured data (Organization, SoftwareApplication,
  BreadcrumbList) to all pages
- Add Open Graph image and Twitter card tags site-wide
- Create branded OG social preview image (1200x630)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Contributor

Documentation Preview Failed

The documentation deployment encountered an error. Please check the deployment logs for more details.

map.set(trimmed, currentDate)
}
}
} catch {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issue: Bare catch block may hide unexpected errors

The empty catch block will silently swallow any error, not just "git not available". For example, if the buffer is too small or there's a permission issue, these would be hidden.

Suggestion: Consider catching specific error types or at least logging the actual error:

} catch (error) {
  console.warn('[sitemap-lastmod] Failed to build lastmod map:', error instanceof Error ? error.message : error)
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Addressed - now logs the actual error message for debugging.

const faviconHref = base.endsWith('/') ? `${base}favicon.svg` : `${base}/favicon.svg`

// Build breadcrumb list from URL path
const siteUrl = 'https://strandsagents.com'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issue: Hardcoded site URL duplicates configuration

The siteUrl is hardcoded here, but Astro already has this configured via Astro.site (which is set in astro.config.mjs).

Suggestion: Use Astro.site?.origin || 'https://strandsagents.com' for consistency with the rest of the codebase and to avoid drift if the domain changes.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Addressed - now using Astro.site?.origin || 'https://strandsagents.com'

<meta name="twitter:image" content={new URL('/og-image.png', Astro.site).href} />

<!-- Structured Data -->
<script type="application/ld+json" set:html={JSON.stringify({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issue: JSON-LD structured data is duplicated

The Organization and SoftwareApplication schemas here are nearly identical to those in Head.astro. This duplication makes maintenance harder and risks inconsistencies.

Suggestion: Extract the shared structured data (Organization, SoftwareApplication) to a utility function or shared constant that both files can import. The landing page could then just add the WebSite/SearchAction schema that's unique to it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Addressed - created src/util/structured-data.ts with shared baseSchemas() function. Nice clean solution!

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Assessment: Comment

Solid improvements to IA and SEO. The navigation consolidation is sensible and the structured data implementation follows best practices.

Review Categories
  • Code Quality: A few opportunities to reduce duplication (JSON-LD schemas) and improve error handling (sitemap plugin)
  • SEO Implementation: Well-structured meta tags and JSON-LD schemas that should improve search visibility
  • Architecture: The additionalBasePaths pattern for nav consolidation is clean and maintainable

The new API language switcher in the sidebar is a nice UX improvement. All tests pass. 🎉

- Log actual error in sitemap-lastmod catch block
- Extract shared JSON-LD schemas to src/util/structured-data.ts
- Use Astro.site?.origin instead of hardcoded site URL in Head.astro
@github-actions
Copy link
Contributor

Documentation Preview Failed

The documentation deployment encountered an error. Please check the deployment logs for more details.

@github-actions
Copy link
Contributor

Documentation Preview Failed

The documentation deployment encountered an error. Please check the deployment logs for more details.

@github-actions
Copy link
Contributor

Documentation Preview Failed

The documentation deployment encountered an error. Please check the deployment logs for more details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant