Experimental JSON decoding API

As feedback from beginners was explicitly requested:
I understood the examplecode right away and had an “aaaahh” moment because:

This style of writing decoders resembles “normal” elm code much more than the current syntax. It was intuitively obvious that I now had access to all previously decoded values, just like I do while pattern matching.

I have written a small elm app for internal tooling so far but did not understand the current syntax enough (even after three tries) to be able to decode a type where one value depends on two others.

I don’t really mind the additional lines of code as I think it fits with the rest of elm which seems to favor being explicit over being concise. Also I am sure elmjutsu and the other awesome plugins would be able to autocomplete a reasonable amount of code.

3 Likes