Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Get rid of runtime exceptions with Elm

Get rid of runtime exceptions with Elm

Presented at - Frontend Meetup Riga #9

Jānis Miezītis

December 14, 2017
Tweet

More Decks by Jānis Miezītis

Other Decks in Programming

Transcript

  1. WHAT IS ELM? ELM is purely functional, immutable and domain

    specific language language, and is developed with emphasis on usability, performance, and robustness. ELM’s compiler catches all possible runtime exceptions. 
 It’s syntax is heavily inspired by Haskell, OCaml and ML.
  2. “In computer science, function composition is an act or mechanism

    to combine simple functions to build more complicated ones.” - Wikipedia
  3. – Tony Hoare, 
 Principle designer of ALGOL 60 “I

    call it my billion-dollar mistake.”
  4. – Joe Armstrong, 
 Creator of Erlang programming language “You

    wanted a banana but what you got was a gorilla holding the banana and the entire jungle.”
  5. LET’S COMPARE ELM React + Redux Both have: Virtual DOM

    Unidirectional data flow Differences: Strictly typed, pure language JavaScript :( Fully immutable No direct access to DOM Optional immutability (with libs) Access to vast ecosystem Has access to DOM if need be Small set of libraries No runtime errors No comment
  6. – Max Kanat-Alexander, Code Simplicity “The difference between a bad

    programmer and a good programmer is understanding. That is, bad programmers don’t understand what they are doing, and good programmers do. Believe it or not, it really is that simple.”