Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

§Classes

AllSelection

A selection type that represents selecting the whole document (which can not necessarily be expressed with a text selection, when there are for example leaf block nodes at the start or end of the document).

EditorState

The state of a ProseMirror editor is represented by an object of this type. A state is a persistent data structure—it isn't updated, but rather a new state value is computed from an old one using the apply method.

NodeSelection

A node selection is a selection that points at a single node. All nodes marked selectable can be the target of a node selection. In such a selection, from and to point directly before and after the selected node, anchor equals from, and head equals to..

Plugin

Plugins bundle functionality that can be added to an editor. They are part of the editor state and may influence that state and the view that contains it.

PluginKey

A key is used to tag plugins in a way that makes it possible to find them, given an editor state. Assigning a key does mean only one plugin of that type can be active in a state.

Selection abstract

Superclass for editor selections. Every selection type should extend this. Should not be instantiated directly.

SelectionRange

Represents a selected range in a document.

TextSelection

A text selection represents a classical editor selection, with a head (the moving side) and anchor (immobile side), both of which point into textblock nodes. It can be empty (a regular cursor position).

Transaction

An editor state transaction, which can be applied to a state to create an updated state. Use EditorState.tr to create an instance.

§Interfaces

EditorStateConfig

The type of object passed to EditorState.create.

PluginSpec

This is the type passed to the Plugin constructor. It provides a definition for a plugin.

SelectionBookmark

A lightweight, document-independent representation of a selection. You can define a custom bookmark type for a custom selection class to make the history handle it well.

StateField

A plugin spec may provide a state field (under its state property) of this type, which describes the state it wants to keep. Functions provided here are always called with the plugin instance as their this binding.

§Type Aliases

Command

Commands are functions that take a state and a an optional transaction dispatch function and...

PluginView

A stateful object that can be installed in an editor by a plugin.