# GroupRowSnapshot (@salmonui/data-grid/engine)

> The GroupRowSnapshot interface of @salmonui/data-grid/engine: Caption or footer row of a group, for renderers and templates.

Canonical: https://salmonui.dev/docs/reference/data-grid/engine/GroupRowSnapshot

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

Also exported from `@salmonui/data-grid`, `@salmonui/data-grid/engine/grouping`.

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

## Reference

Kind: interface

```ts
interface GroupRowSnapshot {
    readonly id: RowId;
    readonly kind: 'group' | 'groupFooter';
    readonly index: number;
    readonly depth: number;
    readonly parentId: RowId | null;
    readonly path: readonly GroupPathSegment[];
    readonly pathKey: string;
    readonly columnId: ColumnId;
    readonly headerText: string;
    readonly key: Json;
    readonly value: unknown;
    readonly formattedKey: string;
    readonly count: number;
    readonly expanded: boolean;
    readonly aggregates: AggregateValues;
    readonly posInSet: number;
    readonly setSize: number;
    readonly status: LazyStatus;
    readonly error: unknown;
    readonly hasMore: boolean;
}
```

Caption or footer row of a group, for renderers and templates.

Members (20):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `id` | `readonly id: RowId;` |  |  |
| `kind` | `readonly kind: 'group' \| 'groupFooter';` |  |  |
| `index` | `readonly index: number;` |  | Visible index. |
| `depth` | `readonly depth: number;` |  | Group level (0 = top). |
| `parentId` | `readonly parentId: RowId \| null;` |  |  |
| `path` | `readonly path: readonly GroupPathSegment[];` |  |  |
| `pathKey` | `readonly pathKey: string;` |  |  |
| `columnId` | `readonly columnId: ColumnId;` |  |  |
| `headerText` | `readonly headerText: string;` |  |  |
| `key` | `readonly key: Json;` |  | JSON form of the key (path segment key). |
| `value` | `readonly value: unknown;` |  | Raw key value (first row's value, or the group-by-format label). |
| `formattedKey` | `readonly formattedKey: string;` |  |  |
| `count` | `readonly count: number;` |  | Data rows in the group (all of them, also in lazy mode). |
| `expanded` | `readonly expanded: boolean;` |  |  |
| `aggregates` | `readonly aggregates: AggregateValues;` |  | Group aggregates as shown (page-wise when paged with `scope: 'page'`). |
| `posInSet` | `readonly posInSet: number;` |  | 1-based position among sibling groups and their number (`aria-posinset`, `aria-setsize`). |
| `setSize` | `readonly setSize: number;` |  |  |
| `status` | `readonly status: LazyStatus;` |  | Lazy mode load state of the group's children; `ready` for local groups. |
| `error` | `readonly error: unknown;` |  |  |
| `hasMore` | `readonly hasMore: boolean;` |  | Lazy mode: more children can be loaded (`grouping.loadMore`). |
