Hi
type alias Circle =
{ x : Float
, y : Float
, radius : Float
}
I have been using elm-format which follows this but I have noticed that I find this style difficult to work with. Let me explain.
I usually sort attributes in records alphabetically. e.g.
type alias Circle =
{ radius : Float
, x : Float
, y : Float
}
This style makes sorting really attributes quite difficult. Consider what needs to be done to add an attribute before `radius`.
Because the style guide suggest using { in front of the first item I can't use my editor automatic sorting command.
I suggest switching to a style where the first items is not preceded by { or [
type alias Circle = {
radius : Float,
x : Float,
y : Float
}
or in case of a list
list = [
'a',
'b'
]
This will mean to put the comma at the end but will make sorting trivial. Please consider this.
Thanks
Sebastian