bloxa

Pagination

FREE

Page links with ellipses, a sliding current marker, first/last buttons, a compact mode and SEO-friendly hrefs.

Installation

Terminal
npx @bloxa/cli add pagination
# or: npx shadcn@latest add @bloxa/pagination

Packages installed automatically: motion

Examples

Variants

API reference

Every component also accepts the props of the element it renders.

Pagination

PropTypeDefaultDescription
page / defaultPagenumber—Current page (from 1).
pageCountnumber—Total pages.
onPageChange(page) => void—When the page changes.
siblings / boundariesnumber1 / 1Pages beside the current one and at the ends.
showEdgesbooleanfalseFirst/last buttons.
compactbooleanfalse"3 / 12" format.
getHref(page) => string—Real links (SEO).