Skip to content

Code folding

Collapse and expand structured regions of a file — functions, blocks, classes, and other language constructs — so you can focus on the part you're working on and hide the rest.

Using it

  • Fold markers appear in the margin next to foldable lines. Click a marker to collapse or expand that region.
  • A collapsed region shows as a single line; expanding it restores the hidden lines.

Folding follows the document's language structure, so the foldable regions match the code's nesting.