longkai / kubernetes-yaml-formatter

Kubernetes Style YAML Formatter for Visual Studio Code
MIT License
41 stars 3 forks source link

Feature request: Configurable `include_document_start` #3

Closed ajhall closed 2 years ago

ajhall commented 2 years ago

yamlfmt includes a setting for include_document_start to control whether documents should start with ---. I'd like to be able to set this to true.

It looks like that would be fairly easy to implement in exactly the same way as compact_sequence_indent: https://github.com/longkai/kubernetes-yaml-formatter/blob/main/src/extension.ts#L75-L95

longkai commented 2 years ago

1.1.0 has beed published to the marketplace and it contains this support.

ajhall commented 2 years ago

Thanks, this works perfectly! I made #4 to fix up the package.json to make it work with the settings page.