Skip to content

getIndentGuides

getIndentGuides(code, tabSize): [number, number, number][]

Defined in: extensions/guides.ts:98

Calculates the position and height of indentation guides for a string of code.

string

Code you want to calculate indentation lines for.

number

Number of spaces a tab is equal to.

[number, number, number][]

An array of indentation guides. Each guide is a tuple containing 3 numbers with the following values:

  • The starting line of the guide.
  • How many tabs the guide is offset to the right.
  • How many lines tall the guide is.