Skip to content

getLines

getLines(text, start, end): readonly [string[], number, number]

Defined in: utils/index.ts:36

Gets all lines that are at least partially between start and end.

string

Text to search in.

number

Start of the selection.

number = start

End of the selection. Defaults to start.

readonly [string[], number, number]

A tuple containing an array of lines, the starting position of the first line, and the ending position of the last line.