Data Grid Server
- from @gridcn
- by gridcn
One server data source for the gridcn data grid: useDataGridServerRows owns sort, filter, search, page and page size, fetches one page per state with a race guard (pages mode) or fixed-size blocks as the rendered rows move, random access over a counted result or a sequential cursor chain (scroll mode), goes back to page 1 on a spec change, keeps the last good rows on screen, and validates every answer, and exposes status, error, retry and refresh. Controlled spec, page and page size pairs take a URL pagination result. Returns gridProps for DataGrid and pager controls for the pagination bar.
Install
New to shadcn? Set up your project
If your project already has a shadcn components.json, skip initialization. Otherwise, run this once from your project root.
pnpm dlx shadcn@latest initpnpm dlx shadcn@latest add @gridcn/data-grid-serverRegistry dependencies2
- @gridcn/data-grid
- @gridcn/data-grid-pagination
Packages0
No npm packages are installed with it.