Give Elm a Chance! (that conference)

2fe1b2866cfd498a513295d60d5cad0f?s=47 Joel Clermont
August 08, 2017
41

Give Elm a Chance! (that conference)

2fe1b2866cfd498a513295d60d5cad0f?s=128

Joel Clermont

August 08, 2017
Tweet

Transcript

  1. 
 Give Elm a Chance! Joel Clermont
 @jclermont

  2. Hello audience

  3. Goal
 You leave here wanting to
 play with Elm for

    an afternoon
  4. What to expect Elm language tour

  5. What to expect What is Elm?

  6. What to expect Why bother with Elm instead of Javascript?

  7. What to expect What makes Elm useful and interesting? •

    Code that doesn’t crash • A powerful type system • Ecosystem: quality over quantity • Care-free refactoring • Amazing QA / debug experience
  8. What is Elm?

  9. What is Elm? Elm is a language that compiles to

    JS
  10. What is Elm? Elm (currently) targets the browser

  11. What is Elm? Elm does not replace PHP, C#, Elixir,

    etc
  12. What is Elm? Elm does not (yet) replace JavaScript

  13. The Elm Architecture

  14. Language + Framework

  15. Model

  16. Update

  17. View

  18. None
  19. No side effects

  20. Questions?

  21. Why bother with Elm instead of Javascript?

  22. None
  23. Why bother with Elm instead of Javascript? User interfaces get

    complex quickly
  24. None
  25. None
  26. None
  27. None
  28. What makes Elm useful and interesting?

  29. No runtime exceptions

  30. No runtime exceptions • Hooray, no bugs! Not quite.

  31. No runtime exceptions • Hooray, no bugs! Not quite. •

    Runtime exceptions are a common class of bugs
  32. No runtime exceptions • Hooray, no bugs! Not quite. •

    Runtime exceptions are a common class of bugs • “undefined is not a function”
  33. No Red Ink’s testimonial Since we began using Elm in

    2015, our production Elm code has yet to cause a single runtime exception. Our error logs show plenty of crashes from our legacy JavaScript code, but none from our Elm code. We've also found our Elm-powered front-end substantially easier to scale than our previous React code base.
  34. Spot the error

  35. Pattern matching

  36. Error handling in types

  37. Algebraic data types

  38. The power of the type system • PHP’s type system

    is getting better, but still basic • C# and Java? Better yet, but not very expressive • ML type system
  39. Data modeling!! https://youtu.be/IcgmSRJHu_8

  40. Refactoring • refactoring can be scary on larger projects, even

    with tests • First few times, I thought it couldn’t possibly be that easy in Elm • Move things around, get everything to compile, done
  41. Questions?

  42. Ecosystem

  43. Elm ecosystem • Package manager enforces semantic versioning

  44. Elm ecosystem • Package manager enforces semantic versioning • API

    design is extremely thoughtful
  45. Elm ecosystem • Package manager enforces semantic versioning • API

    design is extremely thoughtful • Awesome tooling!
  46. Compiler

  47. Editors

  48. Editors

  49. Editors

  50. Editors

  51. Editors

  52. Debugger http://elm-lang.org/assets/blog/0.18/todomvc.html

  53. Ellie https://ellie-app.com/kLKCgY6sK9/0

  54. Bonus Elm Goodies Elm Search Elm CSS Style Elements

  55. Questions?

  56. My story with Elm

  57. My final sales pitch • Welcoming community • Lots of

    effort to making concepts accessible • Easy to use it gradually • Will make you a better JavaScript developer • Developing with Elm is fun!
  58. Closing survey

  59. Next steps • http://elm-lang.org • https://guide.elm-lang.org/ • https://pragmaticstudio.com/elm • https://frontendmasters.com/courses/elm/

    • https://www.dailydrip.com/topics/elm • @elmlang @czaplic @rtfeldman @jclermont
  60. I want to hear from you 
 @jclermont

  61. Questions? @jclermont

  62. Thank you! @jclermont