The pretty printer can fit records onto single lines:
type alias AccessKeyMetadata =
{ userName : UserNameType, status : StatusType, createDate : DateType, accessKeyId : AccessKeyIdType }
but this is definitely better broken:
type alias AccessKeyMetadata =
{ userName : UserNameType
, status : StatusType
, createDate : DateType
, accessKeyId : AccessKeyIdType
}
A better rule is break if >1 field.
Only want to force break in the alias definition, not in pattern matches like { userName, status, createDate, accessKeyId } or in expressions that build records, or in type annotations.
{-| Calc distance between two things that can be 2d points. -}
distance : { a | x : Int, y : Int } -> { b | x : Int, y : Int } -> Int
The pretty printer can fit records onto single lines:
but this is definitely better broken:
A better rule is break if >1 field.
Only want to force break in the alias definition, not in pattern matches like
{ userName, status, createDate, accessKeyId }
or in expressions that build records, or in type annotations.