Skip to content

Option to indent lists relative to mapping keys #42

@bpj

Description

@bpj

Currently lists as values of mapping keys are not indented relative to mapping keys, so that e.g.

{ foo => ['bar', 'baz'] }

becomes

foo:
- bar
- baz

rather than

foo:
  - bar
  - baz

I understand that this is done so that the output shall contain as little whitespace as possible but it is a problem when using indentation as fold method in Vim because such lists will also not stay folded when the level the key is on is unfolded.

The best solution would probably be an option to indent lists relative to mapping keys, since this is a matter of taste.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions