redhat-developer / redhat-developer/vscode-yaml

Add Config for Array Indentation Spacing

Open
#172 41 comments 258 reactions 1 assignee View on GitHub

@msivasubramaniaan is already working on this.

Since Oct 27, 2021.

formatter
Dominant language
TypeScript
Stars
829
Forks
260
Avg merge
5h 43m
Merged PRs (30d)
1

Description

I'm working with Jekyll for GitHub Pages, which uses the Ruby gem for parsing YAML. This gem prefers this spacing in Arrays:

---
simple_val: Testing 1
object_val:
  sub_object_val: Testing 2
array_val:
- Testing 3
- Testing 4

However, when auto-formatter is on, this gets converted to:

---
simple_val: Testing 1
object_val:
  sub_object_val: Testing 2
array_val:
  - Testing 3
  - Testing 4

Regardless of preference, it would be great to have an option to disable adding space indention for arrays.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.