Changelog

biomejs/biome · · 1 commit

Biome YAML formatter learns block scalars

Added YAML literal/folded block scalar formatting, including header comments, indentation handling, and new snapshots/tests.

YAML block scalar formatting lands (dyc3c50a853)

Biome’s YAML formatter now handles literal (|) and folded (>) block scalars instead of leaving them verbatim. The new logic preserves scalar content while reflowing indentation, respecting chomping/indent indicators, and placing header-line comments as dangling comments so they print in the right spot.

This is a meaningful formatter feature because block scalars are common in real YAML, and support here closes a noticeable formatting gap with dedicated parsing, formatting rules, and updated test coverage.

Other misc changes

  • Formatter crate dependency wiring updated for YAML block-scalar work.
  • Added/updated YAML formatter snapshots and line-ending tests for block scalar cases.