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

> The KeyEventLike interface of @salmonui/data-grid/engine: Structural subset of a DOM KeyboardEvent (the engine compiles without the DOM lib).

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

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

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

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 KeyEventLike {
    readonly key: string;
    readonly code?: string;
    readonly ctrlKey: boolean;
    readonly metaKey: boolean;
    readonly altKey: boolean;
    readonly shiftKey: boolean;
}
```

Structural subset of a DOM `KeyboardEvent` (the engine compiles without the DOM lib).

Members (6):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `key` | `readonly key: string;` |  |  |
| `code` | `readonly code?: string;` | optional |  |
| `ctrlKey` | `readonly ctrlKey: boolean;` |  |  |
| `metaKey` | `readonly metaKey: boolean;` |  |  |
| `altKey` | `readonly altKey: boolean;` |  |  |
| `shiftKey` | `readonly shiftKey: boolean;` |  |  |
