Fireship · @fireship

JavaScript for the Haters

Uploaded November 24, 2022 · Length 2:50

JavaScript for the Haters

Summary

A sarcastic rant about the flaws and quirks of the JavaScript programming language, despite its widespread use and popularity.

  • javascript
  • programming language
  • sarcastic rant
  • web development
  • nodejs
  • react native
  • expressjs

Transcript preview

The first 2 minutes of the transcript. Select a timestamp to watch that moment on YouTube.

  1. 0:01

    JavaScript an embarrassing toy language

  2. 0:04

    used exclusively to build things it's

  3. 0:06

    not supposed to it was created by

  4. 0:08

    Brendan Ike in 1995 who was given

  5. 0:10

    requirements to build a language like

  6. 0:11

    Java but for words it only took him

  7. 0:13

    seven days to execute flawlessly it

  8. 0:16

    became an overnight dumpster fire but

  9. 0:18

    really hit the fan in 2005 when

  10. 0:20

    Ryan Dahl made the Epic mistake of

  11. 0:22

    bringing JavaScript to the server with

  12. 0:23

    node.js just like Alfred Nobel and

  13. 0:25

    dynamite he would go on to apologize for

  14. 0:27

    his invention many years later and it's

  15. 0:29

    my fault and I'm very sorry the language

  16. 0:31

    is designed for only one use case to

  17. 0:34

    annoy people with browser pop-ups but

  18. 0:36

    today it's used to build memory hogging

  19. 0:38

    desktop apps with electron janky mobile

  20. 0:40

    apps with react native and unreliable

  21. 0:42

    apis with express.js no matter what

  22. 0:44

    you're trying to build there are

  23. 0:45

    hundreds of different game-changing

  24. 0:46

    next-gen libraries to get the job done

  25. 0:48

    that's because whenever a JavaScript

  26. 0:50

    developer encounters a problem it will

  27. 0:52

    instinctively create a brand new

  28. 0:53

    framework and upload it to GitHub with a

  29. 0:55

    bunch of emojis in the readme in fact

  30. 0:56

    there are so many npm packages that Al

  31. 0:58

    Gore is now predicting the Arctic will

  32. 1:00

    be ice free by 2013 you have stolen my

  33. 1:03

    dreams in my childhood unlike languages

  34. 1:05

    people actually like JavaScript doesn't

  35. 1:07

    have a mascot but they are working with

  36. 1:09

    David Cronenberg to design one it's a

  37. 1:11

    Loosely typed language and by that I

  38. 1:13

    mean completely detached from reality

  39. 1:14

    when you add an array to an object

  40. 1:16

    obviously it returns a string that says

  41. 1:18

    object object now switch the order of

  42. 1:20

    the operands and predictably it returns

  43. 1:22

    zero if you want a good laugh for

  44. 1:24

    yourself try adding two objects together

  45. 1:26

    you'll get object object object object

  46. 1:28

    now with that knowledge what do you

  47. 1:29

    think two arrays will equal obviously an

  48. 1:32

    empty string that makes total sense

  49. 1:33

    because the number zero is equivalent to

  50. 1:35

    an empty array and also equivalent to a

  51. 1:37

    string of zero and that means the only

  52. 1:39

    possible same conclusion is that a

  53. 1:41

    string of zero is also equivalent to an

  54. 1:43

    empty array but amazingly it's not

  55. 1:45

    everybody knows you never go full retire

  56. 1:47

    it got this way because Netscape did a

  57. 1:48

    focus group in the 90s with some

  58. 1:50

    homeless web developers they found on

  59. 1:51

    the street who thought two plus two

  60. 1:53

    should equal 22 and of course that's why

  61. 1:55

    2 minus two equals zero when a language

  62. 1:57

    is this bad and this popular at the same

  63. 1:59

    time it creates an ecosystem where