Utility
AI
Terminal
pagination-demo
No opentui live preview is registered for this example yet.
Installation
pnpm dlx shadcn@latest add @termcn/pagination
Usage
import { Pagination } from "@/components/ui/pagination";<Pagination total={10} current={page} onChange={(p) => setPage(p)} />API Reference
Pagination
| Prop | Type | Default |
|---|---|---|
total | number | required |
current | number | required |
onChange | (page: number) => void | undefined |
showEdges | boolean | true |
siblings | number | 1 |