Base Layout Meta Tags
Thesrc/layouts/Base.astro component handles all SEO meta tags:
Primary Meta Tags
- Canonical URLs prevent duplicate content issues
- Robots directive allows indexing
- Author metadata for content attribution
Hreflang Tags for Multilingual SEO
- Spanish version is at
/es/buscar/ - English version is at
/en/buscar/ - Default language for unlisted regions is Spanish
Open Graph Tags
- Rich previews on Facebook, LinkedIn, WhatsApp
- Proper language tagging for international content
- Custom Open Graph images for better engagement
Twitter Card Tags
summary_large_imagedisplays a large image preview- Optimized for sharing on X/Twitter
Geographic Meta Tags
Structured Data Components
Chapinismos uses multiple schema components for rich search results:OrganizationSchema
Location:src/components/schemas/OrganizationSchema.astro
Defines the organization behind the site (automatically included in Base layout):
WebsiteSchema
Location:src/components/schemas/WebsiteSchema.astro
- Enables Google’s sitewide search box in results
- Defines site structure and purpose
- Multi-language support declaration
WordSchema (DefinedTerm)
Location:src/components/schemas/WordSchema.astro
DefinedTerm: Marks content as a dictionary definitionArticle: Provides article context for search engines- Links to parent DefinedTermSet (the dictionary)
- Conditional fields (category, synonyms) only if present
FAQSchema
Location:src/components/schemas/FAQSchema.astro
- Always includes: Meaning question
- Conditionally adds: Usage examples, category, synonyms
- Creates rich FAQ snippets in Google search results
BreadcrumbSchema
Location:src/components/schemas/BreadcrumbSchema.astro
- Shows breadcrumb trail in search results
- Improves site structure understanding
- Better navigation for users from search
SearchPageSchema
Location:src/components/schemas/SearchPageSchema.astro
Marks the search page with appropriate schema (used in buscar.astro).
Using Schemas in Pages
Schemas are inserted via named slots in the Base layout:Performance Optimizations
Preconnect to External Resources
Preload Background Image
Async Analytics
Sitemap Integration
Best Practices
Always use canonical URLs
Always use canonical URLs
Prevent duplicate content penalties:
Implement hreflang for multilingual sites
Implement hreflang for multilingual sites
Helps Google show the right language version:
Use specific schema types
Use specific schema types
Match schema to content type:
DefinedTermfor dictionary entriesFAQPagefor Q&A contentBreadcrumbListfor navigationSearchActionfor search functionality
Validate structured data
Validate structured data
Use Google’s Rich Results Test:
- https://search.google.com/test/rich-results
- Test each page type
- Verify all required properties
Optimize Open Graph images
Optimize Open Graph images
Ensure images:
- Are at least 1200x630px
- Use absolute URLs
- Have relevant alt text
- Are properly sized (< 300KB)