@helix-x/datagrid-ui - v0.1.2
    Preparing search index...

    Interface CellRendererParams<T, C>

    What ColumnDef.cellRenderer receives.

    interface CellRendererParams<T, C = unknown> {
        api: GridApi<T>;
        column: ColumnDef<T, C>;
        context: C;
        formatted: string;
        row: T;
        rowIndex: number;
        value: unknown;
    }

    Type Parameters

    • T

      The row type.

    • C = unknown

      The context type.

    Index
    api: GridApi<T>

    The live imperative API, for renderers that act on the grid.

    column: ColumnDef<T, C>

    The column being rendered.

    context: C

    Arbitrary app state handed to every renderer. Put volatile things here (in-flight ids, permission checks, handlers) so column definitions can stay memoised on [] and never rebuild.

    formatted: string

    The display string, after ColumnDef.valueFormatter.

    row: T

    The whole row, for cells that need more than their own field.

    rowIndex: number

    Index within the currently loaded page, not the full result set.

    value: unknown

    The raw value, after ColumnDef.valueGetter.