View Source Lexical.Document.Range (lexical_shared v0.0.1)

A range in a document

A range consists of a starting and ending position and includes all text in between.

Note: To select an entire line, construct a range that runs from the first character on the line to the first character on the next line.

whole_line = Range.new(
  Position.new(1, 1),
  Position.new(2, 1)
)

Link to this section Summary

Link to this section Types

@type t() :: %Lexical.Document.Range{
  end: Lexical.Document.Position.t(),
  start: Lexical.Document.Position.t()
}

Link to this section Functions