Table
Tables
We've following types of tables
- Basic
- Collapsible
- Enhanced
- Sticky Header
- Pagination
- Search
- Resizable
- Pinning
- Drag & Drop
We use Tanstack-Table for our table components, here is an basic table example. For more details please check out their official doc here https://tanstack.com/table/latest/docs/introduction
You'll find all our tables in action https://isomorphic-furyroad.vercel.app/tables/basic
apps/packages/isomorphic-core/src/components/table/index.tsx
"use client";
import Table from "@core/components/table";
import { useTanStackTable } from "@core/components/table/custom/use-TanStack-Table";
export default function RecentCustomers({ className }: { className?: string }) {
const { table } = useTanStackTable<RecentCustomersDataType>({
tableData: recentCustomers, // data array
columnConfig: recentCustomersColumns, // column config
options: {
initialState: {
pagination: {
pageIndex: 0,
pageSize: 7,
},
},
enableColumnResizing: false,
},
});
return (
<>
<Table table={table} />
</>
);
}