Ellie – An Elm Live Editor
(Ellie is really cool, apologies for the meta comment, but):<p>It&#x27;s a shame that all that hits me in the face with Elm code examples lately is awkward style conventions. Why do they have to be so user hostile?<p>Trailing brace on the next line even for this?<p><pre><code>    type alias Model =
    { counter : Int
    }
</code></pre>
Instead of:<p><pre><code>    type alias Model = { counter: Int }
</code></pre>
Comma first, when trailing comma is so much more intuitive, why this?<p><pre><code>    Html.program
        { view = view
        , update = update
        , subscriptions = \_ -&gt; Sub.none
        , init = ( model, Cmd.none )
        }
</code></pre>
instead of:<p><pre><code>    Html.program {
        view = view,
        update = update,
        subscriptions = \_ -&gt; Sub.none,
        init = ( model, Cmd.none ),
    }
</code></pre>
(... which makes for better diffs too). And weird bracket soup for DOM:<p><pre><code>    div []
        [ div [] [ button [ onClick Increment ] [ text &quot;+&quot; ] ]
        , div [] [ text &lt;| toString model.counter ]
        , div [] [ button [ onClick Decrement ] [ text &quot;-&quot; ] ]
        ]
</code></pre>
... when it&#x27;s going to be translated to DOM anyway, why not?<p><pre><code>    &lt;div&gt;
        &lt;div&gt;&lt;button onClick={increment}&gt;+&lt;&#x2F;button&gt;&lt;&#x2F;div&gt;
        &lt;div&gt;{toString model.counter}&lt;&#x2F;div&gt;
        &lt;div&gt;&lt;button onClick={decrement}&gt;-&lt;&#x2F;button&gt;&lt;&#x2F;div&gt;
    &lt;&#x2F;div&gt;
</code></pre>
This is needlessly distracting from all the things that are nice about Elm.