Utility
AI
Terminal
sparkline-demo
No opentui live preview is registered for this example yet.
Installation
pnpm dlx shadcn@latest add @termcn/sparkline
Usage
import { Sparkline } from "@/components/ui/sparkline";<Sparkline data={[4, 8, 15, 16, 23, 42, 38, 26]} width={20} label="Requests" />API Reference
Sparkline
| Prop | Type | Default |
|---|---|---|
data | number[] | required |
width | number | 20 |
color | string | undefined |
label | string | undefined |