# ExportDataGridOptions (@salmonui/data-grid/engine/export-server)

> The ExportDataGridOptions interface of @salmonui/data-grid/engine/export-server: Rows and columns of a headless export grid.

Canonical: https://salmonui.dev/docs/reference/data-grid/engine-export-server/ExportDataGridOptions

```ts
import type { ExportDataGridOptions } from '@salmonui/data-grid/engine/export-server';
```

Entry index: https://salmonui.dev/docs/reference/data-grid/engine-export-server (Markdown with every symbol of the entry: https://salmonui.dev/docs/reference/data-grid/engine-export-server.md).

## Reference

Kind: interface

```ts
interface ExportDataGridOptions<Row> {
    readonly rows: readonly Row[];
    readonly columns: readonly ColumnDef<Row>[];
    readonly getRowId?: (row: Row, index: number) => RowId;
    readonly query?: DataGridQueryInit;
    readonly state?: DataGridState | string;
    readonly locale?: string;
    readonly timeZone?: string;
    readonly currency?: string;
    readonly direction?: 'ltr' | 'rtl';
    readonly tree?: TreeOptions<Row> | true;
}
```

Rows and columns of a headless export grid.

Members (10):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `rows` | `readonly rows: readonly Row[];` |  |  |
| `columns` | `readonly columns: readonly ColumnDef<Row>[];` |  |  |
| `getRowId` | `readonly getRowId?: (row: Row, index: number) => RowId;` | optional | Default: the `primaryKey` column's value, else the row index. |
| `query` | `readonly query?: DataGridQueryInit;` | optional | Sorting, filters, search, grouping, aggregates, and paging. |
| `state` | `readonly state?: DataGridState \| string;` | optional | A client grid state (`getState()`, or its `serializeDataGridState` text), applied after `query`. |
| `locale` | `readonly locale?: string;` | optional |  |
| `timeZone` | `readonly timeZone?: string;` | optional |  |
| `currency` | `readonly currency?: string;` | optional |  |
| `direction` | `readonly direction?: 'ltr' \| 'rtl';` | optional |  |
| `tree` | `readonly tree?: TreeOptions<Row> \| true;` | optional | Tree mode: the same `tree` options as the client grid (`true` means nested rows under `children`). Nested `rows` are flattened here; a client `state` restores `tree.expandedRows`. The export model then carries each row's depth, so XLSX outlines, PDF indentation, and the CSV depth column equal the client export. |
