Elm-format alternative

Yes, I thought about this. Not a bad idea for some of the changes (eg lining up |> with the first letter on it’s lhs).

So what I’m looking for is avoiding extra spacing and lines. The compact branch of timjs/elm-format does a lot of this, especially removing extra lines between case conditions and between functions. Some extra that I’m looking for:

  • dont go to newlines quite so quickly in ifs and cases (use line-length to decide)
  • dont add a newline before the first let-def in a let
  • lets with one def that fit on a line should stay on that line, including the in at the end
  • dont indent before |>

Ideally I’d also get to split imports into groups (core, libs, and our stuff) but I won’t die on that hill.

1 Like