Open GitHub repository
ComponentsData Table

Data Table

Renders typed row data through configurable columns with optional client-side sorting.

Installation

bunx @swift-rust/ui add data-table

Usage

tsx
1import { DataTable } from "@/components/ui/data-table";
2 
3const columns = [
4 { key: "name", header: "Name", sortable: true },
5 { key: "role", header: "Role" },
6];
7 
8<DataTable
9 columns={columns}
10 data={[{ name: "Ada", role: "Owner" }, { name: "Grace", role: "Admin" }]}
11/>