This is the Capgo landing website built with Astro.
Always use bun instead of npm or yarn.
- Install dependencies:
bun install - Run scripts:
bun run <script> - Add packages:
bun add <package> - Remove packages:
bun remove <package>
When creating or modifying pages, always consider SEO:
- Use the helpers in
src/lib/ldJson.tsto add structured data - Service pages should use
createServiceLdJsonwithcreateLdJsonGraph - Blog posts use
createNewsArticleLdJson - FAQ sections should include
createFAQPageLdJson - List/catalog pages should use
createItemListLdJson - Always include organization data via
includeOrganization: true
- Every page must have a unique
titleanddescription - Blog posts should include article-specific OG tags:
ogType: 'article'articlePublishedTimearticleModifiedTimearticleSectionarticleTags
- Use
keywordsprop for relevant search terms
- Use semantic HTML headings (h1, h2, h3) in proper hierarchy
- Include descriptive alt text for all images
- Use canonical URLs for duplicate content
- Ensure hreflang tags are present for localized pages
- Add
aria-labelto interactive elements without visible text - Use
aria-hidden="true"on decorative SVGs and icons - Add
role="img"witharia-labelto icon containers - Use
aria-live="polite"for dynamic content updates - Add
aria-expandedto dropdown toggles
- All interactive elements must be keyboard accessible
- Include skip navigation link (already in Layout.astro)
- Ensure visible focus states on all focusable elements
- Use proper focus management in modals and dropdowns
- Use
<main>landmark for primary content - Use
<nav>for navigation sections - Use
<header>and<footer>appropriately - Use
<section>with proper headings
- All inputs must have associated labels or
aria-label - Use
aria-describedbyfor error messages - Group related fields with
<fieldset>and<legend>
- All images must have descriptive
alttext - Decorative images should have
alt="" - Iframes must have
titleattribute
- Pages:
src/pages/ - Components:
src/components/ - Layouts:
src/layouts/ - Translations:
src/paraglide/messages.ts - SEO helpers:
src/lib/ldJson.ts - Styles: Tailwind CSS
The project includes a comprehensive SEO static checker that runs after each build. It validates:
- Metadata (title, description, canonical, charset, lang)
- HTML validity (duplicate tags, doctype, duplicate IDs)
- Content length (title, description, H1 length limits)
- Headings (H1 presence, heading hierarchy)
- Links (broken links, empty hrefs, generic anchor text)
- Images (alt attributes, broken images, file size)
- Social tags (OpenGraph, Twitter cards)
- International SEO (hreflang validation)
- Structured data (JSON-LD validation)
- Duplicates (across pages)
seo-checker.config.json- Main configuration fileseo-checker.exclusions.json- Specific issue exclusions
To exclude a specific issue, add it to seo-checker.exclusions.json:
{
"exclusions": [
{
"fingerprint": "SEO00147::blog/old-post/index.html::/broken-link",
"reason": "Legacy link, intentionally kept for redirects"
},
{
"ruleId": "SEO00153",
"filePath": "icons/**/*.html",
"reason": "Icon pages use decorative images"
}
]
}Exclusion types (from most to least specific):
fingerprint- Exact issue match (rule + file + element)ruleId+filePath- Rule for specific file patternruleId+elementPattern- Rule for specific element contentruleId- Disable entire rule (use config.rules.disabled instead)
bun run dev # Start development server
bun run build # Build for production
bun run preview # Preview production build
bun run seo:check # Run SEO checker manually
bun run seo:check:json # Output as JSON
bun run seo:check:report # Save report to file