aaubry / YamlDotNet

YamlDotNet is a .NET library for YAML
MIT License
2.48k stars 466 forks source link

Add new line between items #871

Open sunnamed434 opened 7 months ago

sunnamed434 commented 7 months ago

Looking for a way of adding new line per every new line

var yamlSerializer = new SerializerBuilder()
.AddNewLinePerEveryNewItem() // smth like this or similar API
.Build()

Before:

first1:
  hello: true
  world: true
there:
  a: true
  b: true
  c: true
first2:
  a: false

After:

first1:
  hello: true
  world: true

there:
  a: true
  b: true
  c: true

first2:
  a: false