Skip to Content
ComponentsPricing

Pricing

The Pricing component provides you with pricing tables and plans.

Live Examples

Live Example
☀️
Copy
View Code
import { Pricing } from '@jarllyng/nostromo' export default function PricingExample() { return ( <Pricing title="Choose Your Plan" subtitle="Flexible pricing for teams of all sizes" plans={[ {...
Live Example
☀️
Copy
View Code
import { Pricing } from '@jarllyng/nostromo' export default function PricingComparisonExample() { return ( <Pricing title="Compare Plans" variant="muted" columns={3} plans={[ {...
Live Example
☀️
Copy
View Code
import { Pricing } from '@jarllyng/nostromo' export default function PricingSimpleExample() { return ( <Pricing title="Simple Pricing" columns={2} plans={[ { id: 'monthly',...

Import

import { Pricing } from "@jarllyng/nostromo"; // or import { Pricing } from "@jarllyng/nostromo/pricing";

Usage

import { Pricing } from "@jarllyng/nostromo"; export default function Example() { return ( <Pricing title="Choose Your Plan" plans={[ { name: "Starter", price: "$9", period: "month", features: ["Feature 1", "Feature 2"], }, ]} /> ); }

Code Examples

Props

PropTypeDefaultRequiredDescription
plansPricingPlan[]-YesArray of pricing plans (see PricingPlan interface below)
titlestringundefinedNoSection title
subtitlestringundefinedNoSection subtitle
columns1 | 2 | 3 | 43NoNumber of columns in grid
variant"default" | "featured" | "comparison""default"NoVisual variant
showYearlybooleanfalseNoWhether to show yearly billing toggle
onToggleBilling(yearly: boolean) => voidundefinedNoCallback when billing period toggles
classNamestringundefinedNoAdditional CSS classes

PricingPlan Interface

interface PricingPlan { name: string; price: string; period?: string; description?: string; features: string[]; cta?: React.ReactNode | string; popular?: boolean; badge?: string; }
Last updated on