Elm and good design
In his presentation “What is Success?”, Elm’s creator Evan Czaplicki admires a Braun radio designed by Dieter Rams:
“I can’t make things as cool as that radio…”
Would Dieter Rams agree? In what ways does the Elm language exemplify Rams’s iconic 10 principles of good design?
Let’s review each principle.
Good design:
- ๐ฅ Is innovative
- ๐จ Makes a product useful
- ๐บ Is aesthetic
- ๐ก Makes a product understandable
- ๐ถ๏ธ Is unobtrusive
- โ๏ธ Is honest
- โฐ๏ธ Is long-lasting
- ๐ฌ Is thorough
- ๐ณ Is environmentally friendly
- ๐ Is as little design as possible
๐ฅ Innovative
Elm brings pure functional programming to front-end web development. Front-end had never been served by this paradigm before.
๐จ Useful
Elm’s static types and pure functions create numerous guarantees, making software development predictable and scalable.
๐บ Aesthetic
Members of the Elm community are quick to express the emotional satisfaction of refactoring huge parts of their codebase and arriving at a working result.
๐ก Understandable
Elm is easy to learn, and its lack of side-effects makes application code easier to understand, maintain and debug.
๐ถ๏ธ Unobtrusive
Most Elm developers use elm-format
, an automatic formatting tool that is standardized and non-configurable by design. So the layout of most Elm code will not surprise you.
โ๏ธ Honest
Elm requires you to handle all cases of your application state. This removes the possibility of runtime errors due to unhandled cases.
โฐ๏ธ Long-lasting
Some applications are cheaper to rebuild than to refactor. But Elm applications are easy to refactor confidently, which means codebases can remain useful longer.
๐ฌ Thorough
Elm’s custom types allow you to model your domain much more precisely and correctly than is capable with JavaScript objects. This allows program states to be more accurate and less capable of producing errors.
๐ณ Environmentally friendly
Elm’s compiled asset sizes are the smallest among React, Vue, and Angular 2. If all web applications used Elm, their download size would be smaller on average by a factor of (at least) 2.5.
๐ Minimal
In the Elm core libraries, there is mostly only one way of doing something (e.g. rendering HTML, producing an HTTP request, parsing, etc.). This minimalism means easier communication between developers on a project.
This post was originally a Twitter thread as part of Ship 30 for 30.