nvim-treesitter/queries/yaml/indents.scm
Phelipe Teles 8bd07c88b6 fix(indents/yaml): only indent mapping pair if value is a block
This improves the following situation, in which '|' is the cursor position:

```yaml
- key1: value1
  key2: value2|
```

Before this commit, by pressing Enter would result in this indentation:

```yaml
- key1: value1
  key2: value2
    |
```

Which is less convenient than this:

```yaml
- key1: value1
  key2: value2
  |
```
2022-06-14 22:37:52 +02:00

6 lines
94 B
Scheme

[
(block_mapping_pair value: (block_node))
(block_sequence_item)
] @indent
(ERROR) @auto