Should there be an example of destructuring in let in? let (Foo foo) = bar
Should there be a toplevel definition without a type annotation?
And a let inwith a type definition? Maybe also one where a “type variable is re-used from the parent function type annotation” (I think that’s a thing).
Maybe a multi-line type annotation?
Is there any formatting we want to add, that elm-format does not output? Such as single-line if.
It’s just playing. No serious goals here. I sometime get questions in my mind that I would like answered. I guess I do am interested in how low can one go. Can all these things be expressed in less code?
I have produced a new version integrating the suggestions that were easier to think through.
Is there any formatting we want to add, that elm-format does not output? Such as single-line if.
I love the uniformity of elm-format and I would like the example to stay formatted. But you have a good point here. I know that Evan publishes code that has unconventional formatting ( like this section ) and single line ifs that fit into the line width limit are one of the things I wish elm-format would allow.
It is very funny how I missed partial application as this is something I do all the time. Using infix operators in higher order functions is less frequent in my code but still… I use it from time to time. The use-case for infix operator as prefix function that I have in my code is actually partial application of the operator.