X Enterprises
nuxt-x-schema

Review

Schema.org Review and AggregateRating JSON-LD component for product and service reviews.

Review

The XSchemaReview component injects a <script type="application/ld+json"> tag for review or aggregate rating structured data. No visible output — SEO only.

Components

<XSchemaReview />

Use on product, service, or business pages. Toggle between a single Review and an AggregateRating via the isAggregate prop.

<XSchemaReview
  :item-reviewed="{ '@type': 'Product', name: 'Headphones' }"
  :review-rating="{ ratingValue: 5, bestRating: 5 }"
  author="Jane Doe"
  review-body="Excellent sound quality!"
/>

Props

PropTypeRequiredDefaultDescription
itemReviewedRecord<string, any>Yes—The item being reviewed (include @type and name)
reviewRatingRatingYes—Rating object { ratingValue, bestRating? }
authorString | PersonYes—Reviewer name or Person object
reviewBodyStringNo—Full review text
datePublishedStringNo—ISO 8601 review date
isAggregatebooleanNofalseWhen true, outputs AggregateRating schema instead of individual Review
ratingCountNumberNo—Total rating count (aggregate mode)
reviewCountNumberNo—Total review count (aggregate mode)

AI Context

component: XSchemaReview
package: "@xenterprises/nuxt-x-schema"
output: JSON-LD script tag in <head>
use-when: Adding Review or AggregateRating structured data on product, service, or business pages
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
  - isAggregate=true switches output from Review to AggregateRating schema
  - itemReviewed must include @type and name
Copyright © 2026