FAQ
The FAQ component renders a list of expandable questions and answers (Accordions), marked up with JSON-LD Schema for SEO.
Usage
import FAQ from '~/components/sections/FAQ.astro';
const items = [
{ question: "Is this free?", answer: "Yes, it is open source." },
{ question: "Can I use it for commercial projects?", answer: "Absolutely!" }
];
<FAQ
title="Frequently Asked Questions"
items={items}
/>
Example
Preguntas Frecuentes
Todo lo que necesitas saber sobre el producto y la facturación.
How does it work?
It uses the HTML details and summary elements.
Is it accessible?
Yes, it uses native browser semantics.
Props
| Prop | Type | Description |
|---|---|---|
title | string | The section heading (optional). |
items | { question: string, answer: string }[] | Array of Q&A objects. |