Skip to content

Getting started — Adapters

The framework adapters are thin views over @tensorgrid/core (the parity-verified TypeScript port of the Polars engine). Pass raw data + a grouping — the adapter does zero math.

  1. Install the adapter for your framework (plus @tensorgrid/core):

    Terminal window
    npm i @tensorgrid/react @tensorgrid/core
  2. Render a grid:

    import { TensorGrid } from '@tensorgrid/react';
    export function App({ data }) {
    return (
    <TensorGrid
    data={data}
    rows={['region', 'country']}
    measures={{ revenue: 'sum', cost: 'sum' }}
    formats={{ revenue: '$0,0', cost: '$0,0' }}
    grandTotal
    />
    );
    }

The vanilla adapter has no peer dependencies — it renders the same grid with createElement, so it drops into any page. Here it is live:

Every adapter also ships opt-in built-in chrome (search, export, selection toolbar, density toggle, column visibility, status bar, keyboard nav) and the same interaction surface — see the guides. For every prop and option, see the Adapter API reference.