nuxt-x-schema
FAQ
Schema.org FAQPage JSON-LD component for frequently asked questions structured data.
FAQ
The XSchemaFAQ component injects a <script type="application/ld+json"> tag for FAQ structured data. No visible output — SEO only.
Components
<XSchemaFAQ />
Use on pages containing a list of frequently asked questions and answers. Enables rich results in Google Search with expandable Q&A dropdowns.
<XSchemaFAQ
:items="[
{ label: 'What is Vue?', content: 'A progressive JavaScript framework.' },
{ label: 'Is it free?', content: 'Yes, MIT licensed.' }
]"
/>
Props
| Prop | Type | Required | Description |
|---|---|---|---|
items | FAQ[] | Yes | Array of FAQ items. Each item accepts: label/question/name for the question; content/answer/text for the answer |
pageTitle | String | No | Optional page name added to the schema |
pageDescription | String | No | Optional page description |
datePublished | String | No | ISO 8601 publish date |
dateModified | String | No | ISO 8601 modified date |
author | String | Person | No | Page author |
AI Context
component: XSchemaFAQ
package: "@xenterprises/nuxt-x-schema"
output: JSON-LD script tag in <head>
use-when: Adding FAQPage structured data to pages with frequently asked questions
place: In page-level components (pages/ or layouts/), NOT in shared headers
notes:
- Renderless component — no visible DOM output; purely SEO metadata
- Injects JSON-LD server-side via useHead — SSR-safe, visible to crawlers on first paint
- FAQ items accept label/question/name for question and content/answer/text for answer
