ProsemirrorEx.Transform.ReplaceStep (prosemirror_ex v0.3.0)

Copy Markdown View Source

Replace a part of the document with a slice of new content.

Ports ReplaceStep from prosemirror-transform/src/replace_step.ts.

Summary

Types

t()

@type t() :: %ProsemirrorEx.Transform.ReplaceStep{
  from: non_neg_integer(),
  slice: ProsemirrorEx.Model.Slice.t(),
  structure: boolean(),
  to: non_neg_integer()
}

Functions

new(from, to, slice, structure \\ false)

Create a new ReplaceStep.