# PivotComputeEvent (@salmonui/pivot-table)

> The PivotComputeEvent interface of @salmonui/pivot-table: onComputeStart / onComputeEnd.

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

```ts
import type { PivotComputeEvent } 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 PivotComputeEvent extends PivotEvent {
    readonly phase: 'initial' | 'update';
    readonly status: PivotComputeStatus;
    readonly duration: number;
    readonly result: PivotResult | null;
}
```

`onComputeStart` / `onComputeEnd`.

Members (8):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `phase` | `readonly phase: 'initial' \| 'update';` |  |  |
| `status` | `readonly status: PivotComputeStatus;` |  |  |
| `duration` | `readonly duration: number;` |  | Milliseconds from start to end (end event only; 0 on start). |
| `result` | `readonly result: PivotResult \| null;` |  |  |
| `type` | `type: string;` | inherited | `'sortChange'`, `'beforeSortChange'`, ... |
| `source` | `source: DataGridEventSource;` | inherited |  |
| `defaultPrevented` | `defaultPrevented: boolean;` | inherited | True after `preventDefault()` (before-events and click events). |
| `preventDefault` | `preventDefault: () => void;` | inherited | Before-events and click events: cancels the action (or the built-in behavior). |
