# InlineEditApi (@salmonui/editors/inline-edit)

> The InlineEditApi interface of @salmonui/editors/inline-edit: Ref handle: the Data Grid edit method names.

Canonical: https://salmonui.dev/docs/reference/editors/inline-edit/InlineEditApi

```ts
import type { InlineEditApi } from '@salmonui/editors/inline-edit';
```

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

## Reference

Kind: interface

```ts
interface InlineEditApi {
    readonly element: HTMLSpanElement | null;
    startEdit(): void;
    save(): Promise<boolean>;
    cancelEdit(): void;
    validate(): Promise<readonly string[]>;
}
```

Ref handle: the Data Grid edit method names.

Members (5):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `element` | `readonly element: HTMLSpanElement \| null;` |  | The root element. |
| `startEdit` | `startEdit(): void;` |  |  |
| `save` | `save(): Promise<boolean>;` |  | Saves the draft; resolves to true when the value was saved. |
| `cancelEdit` | `cancelEdit(): void;` |  |  |
| `validate` | `validate(): Promise<readonly string[]>;` |  | Validates the draft (or the saved value when idle) and resolves to the error list. |
