A set of reusable, styled table components for building accessible and consistent data tables in React applications.
// Source: https://github.com/Deen-Bridge/dnb-frontend | License: MIT | Copyright 2025 Deen Bridge
// Provided via justclaw.it.com; keep this notice with the code.
"use client"
import * as React from "react"
import { cn } from "@/lib/utils"
function Table({
className = "",
...props
}) {
return (
(<div data-slot="table-container" className="relative w-full overflow-x-auto">
<table
data-slot="table"
role="table"
className={cn("w-full caption-bottom text-sm", className)}
{...props} />
</div>)
);
}
function TableHeader({
className = "",
...props
}) {
return (
(<thead
data-slot="table-header"
className={cn("[&_tr]:border-b", className)}
{...props} />)
);
}
function TableBody({
className = "",
...props
}
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key