nuxt-x-schema
VideoObject
Schema.org VideoObject JSON-LD component for video content structured data.
VideoObject
The XSchemaVideoObject component injects a <script type="application/ld+json"> tag for video structured data. No visible output — SEO only.
Components
<XSchemaVideoObject />
Use on pages embedding a video (tutorials, demos, interviews). Enables rich results in Google Video Search with thumbnail, duration, and upload date.
<XSchemaVideoObject
name="Introduction to Vue 3"
description="A beginner-friendly overview of Vue 3"
thumbnail-url="https://example.com/thumb.jpg"
upload-date="2024-01-10"
content-url="https://example.com/video.mp4"
duration="PT12M30S"
/>
Props
| Prop | Type | Required | Description |
|---|---|---|---|
name | String | Yes | Video title |
description | String | Yes | Video description |
thumbnailUrl | String | String[] | Yes | Thumbnail image URL(s) |
uploadDate | String | Yes | ISO 8601 upload date |
duration | String | No | ISO 8601 duration (e.g. PT1H30M) |
contentUrl | String | No | Direct URL to the video file |
embedUrl | String | No | Embed URL (e.g. YouTube embed) |
interactionCount | Number | No | Number of views/interactions |
author | String | Person | No | Creator name or Person object |
AI Context
component: XSchemaVideoObject
package: "@xenterprises/nuxt-x-schema"
output: JSON-LD script tag in <head>
use-when: Adding VideoObject structured data on pages embedding video content
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
- duration uses ISO 8601 format (e.g. PT12M30S for 12 minutes 30 seconds)
- Provide either contentUrl or embedUrl (or both)
