Back to Components
Display

Table

Styled table component with header, body, and row variants.

PropsUsage ExampleVariations
A list of your recent invoices.
InvoiceStatusMethodAmount
INV001PaidCredit Card$250.00
INV002PendingPayPal$150.00
INV003UnpaidBank Transfer$350.00
INV004PaidCredit Card$450.00
INV005PaidPayPal$550.00
INV006PendingBank Transfer$200.00
INV007UnpaidCredit Card$300.00
Total$2,250.00

Dependencies

  • clsx
  • tailwind-merge

Files

  • components/ui/table.tsx

Installation

Using shadcn CLI

npx shadcn add table --url https://ui.hampton.io

Manual installation

Copy the component file to your project and install dependencies:

npm install clsx tailwind-merge

Related Display Components