# PivotPersistState (@salmonui/pivot-table)

> The PivotPersistState interface of @salmonui/pivot-table: Persistence.

Canonical: https://salmonui.dev/docs/reference/pivot-table/PivotPersistState

```ts
import type { PivotPersistState } from '@salmonui/pivot-table';
```

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

## Reference

Kind: interface

```ts
interface PivotPersistState {
    readonly id: string;
    readonly storage?: {
        getItem(key: string): string | null;
        setItem(key: string, value: string): void;
        removeItem?(key: string): void;
    } | undefined;
    readonly version?: string | undefined;
}
```

Persistence.

Members (3):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `id` | `readonly id: string;` |  | Storage key suffix: `salmon-pivot-table:<id>`. |
| `storage` | `readonly storage?: {     getItem(key: string): string \| null;     setItem(key: string, value: string): void;     removeItem?(key: string): void; } \| undefined;` | optional | Default `localStorage`. |
| `version` | `readonly version?: string \| undefined;` | optional | Saved states of another application version are ignored. |
