blockSequences
Prefer block style sequences over flow style sequences.
✅ This rule is included in the yaml stylistic presets.
Block style sequences use hyphens (-) to denote list items and are generally more readable for multi-item lists.
Flow style sequences use brackets ([]) and are more compact but less clear in most cases.
Examples
Section titled “Examples”items: [a, b, c]nested: values: [1, 2, 3]items: - a - b - cnested: values: - 1 - 2 - 3Options
Section titled “Options”This rule is not configurable.
Further Reading
Section titled “Further Reading”Equivalents in Other Linters
Section titled “Equivalents in Other Linters”- ESLint:
yml/block-sequence
Made with ❤️🔥 in Boston by
Josh Goldberg and contributors.