# RichTextExtensionContext (@salmonui/rich-text)

> The RichTextExtensionContext interface of @salmonui/rich-text: What an extension's plugin factory receives.

Canonical: https://salmonui.dev/docs/reference/rich-text/RichTextExtensionContext

```ts
import type { RichTextExtensionContext } from '@salmonui/rich-text';
```

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

## Reference

Kind: interface

```ts
interface RichTextExtensionContext {
    readonly schema: Schema;
    getState(): EditorState;
    getView(): EditorView | null;
}
```

What an extension's plugin factory receives.

Members (3):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `schema` | `readonly schema: Schema;` |  |  |
| `getState` | `getState(): EditorState;` |  | The engine's current state (after mount the view's state). |
| `getView` | `getView(): EditorView \| null;` |  | The view once mounted. |
