X Enterprises
nuxt-x-affiliate

Pricing Comparison

Feature-by-feature comparison table across several plans, grouped into sections.

Pricing Comparison

A feature-by-feature comparison across several plans, grouped into sections.

An adapter over Nuxt UI's <UPricingTable>; what it adds is the readable input shape — plans keyed by id, features grouped into sections, each feature carrying a values map of planId → boolean | string.

For a "which plan should I buy" page this usually outperforms prose.

Components

<XAFPricingComparison />

<XAFPricingComparison
  :plans="plans"
  :feature-groups="groups"
  caption="Plan comparison"
  :badges="['money-back']"
/>

<script setup>
const plans = [
  { id: 'starter', name: 'Starter', price: '$9/mo', button: { label: 'Get Started' } },
  { id: 'pro', name: 'Pro', price: '$29/mo', highlighted: true, button: { label: 'Get Pro' } },
]

const groups = [
  {
    name: 'Core',
    features: [
      { name: 'Projects', values: { starter: '5', pro: 'Unlimited' } },
      { name: 'Priority support', values: { starter: false, pro: true } },
    ],
  },
]
</script>

Props

PropTypeDefaultDescription
plansComparisonPlan[]requiredTable columns
featureGroupsFeatureGroup[]requiredGrouped rows
captionstring—Table caption, read before the table
badgesBadge[][]Trust badges above or below the table
badgesPosition'top' | 'bottom''bottom'Badge row position
badgesAlign'left' | 'center' | 'right''center'Badge row alignment

ComparisonPlan object

KeyTypeDescription
idstringStable key referenced by each feature's values map
namestringColumn heading
pricestringPrice line
descriptionstringLine under the name
highlightedbooleanEmphasise this column
button{ label }Column call-to-action

FeatureGroup object

KeyTypeDescription
namestringSection heading. Omit for an ungrouped run
features{ name, values }[]Rows. values maps planId to boolean | string

Events

EventPayloadDescription
selectComparisonPlanA column's button was clicked

Tips

  • The table scrolls inside its own container on narrow screens rather than forcing the page to scroll horizontally.

AI Context

component: XAFPricingComparison
package: "@xenterprises/nuxt-x-affiliate"
use-when: Feature-by-feature plan comparison table
Copyright © 2026