tamasfe / taplo

A TOML toolkit written in Rust
https://taplo.tamasfe.dev
MIT License
1.26k stars 108 forks source link

Align keys of array<inline tables> #596

Open theelderbeever opened 2 months ago

theelderbeever commented 2 months ago

This might already exist and I just haven't been able to get the conifg correct but, it would be nice if the formatter could auto align the matching keys of consecutive inline tables in an array such as the following

[config]
map = [
  { key = "hello",     value = "world" },
  { key = "goodbye",   value = "world" },
]

as opposed to

[config]
map = [
  { key = "hello", value = "world" },
  { key = "goodbye", value = "world" },
]