Skip to content

Instantly share code, notes, and snippets.

@tonymorris
Created October 13, 2012 07:20
Show Gist options
  • Save tonymorris/3883650 to your computer and use it in GitHub Desktop.
Save tonymorris/3883650 to your computer and use it in GitHub Desktop.
JavaScript idiot on Youtube
  • Why he doesn't use JavaScript to show examples of closure is beyond me.

JavaScript is an awful language to both demonstrate and practice functional programming.

  • You have no idea what you're talking about. Functions are first-class in JavaScript. Nine times out of ten, those who hate JavaScript just don't understand it and/or suck at it.

Ugh, well this is going to get silly.

I don't know what I am talkin about. I have been teaching functional programming for around a decade. I am currently writing a book FP. I use Haskell in my day job primarily and many other languages, including, unfortunately JavaScript. I have written two ECMA-compliant JavaScript compilers. Unfortunately, I am very intimate with both functional programming and JavaScript. Oh, you know functional programming library mentioned at 25:50? I wrote that.

That's the wanky stuff out of the way.

I am acutely aware "functions are first-class in JavaScript." This has no bearing at all on the statement, "JavaScript is an awful language to both demonstrate and practice functional programming." JavaScript's presence of first-class functions and ability to adhere to, and demonstrate, the functional programming thesis are orthogonal concepts. You would know this if you knew what FP means and if you had a better understanding of JavaScript, so from here, I will assume you do not.

Given that you are lacking in this knowledge, and you are clearly passionate (even hot-headed), about this subject, I would like to extend to you an invitation to understand it better. I will help you achieve this. In particular, I will teach you what functional programming means. Never mind JavaScript -- you can revisit that once you have a better understanding of the topics involved.

This is a genuine offer, right here, on a Youtube comment.

  • Dafuq is all of this? I know what functional programing is, and, no, I do not care to extend this discussion beyond petty remarks, to be honest. If you think you know everything, that is fantastic for you.

It is an offer to "know what you are talking about", which you seem to be interested in. I very much doubt you do know what functional programming is, given your original comment.

I do not think I know everything, nor was it implied. If making silly remarks is your chosen path, fine, but don't expect to be taken seriously by thinking people -- it won't happen. Some of them will point at you and laugh. I prefer to get over it and exchange ideas instead.

It's your call. That's all it is.

  • Excellent. You win. Congratulations.

There iss no competition here mate. Just an invitation. Want to get stuck into it? Happy to help.

  • Look, just use Google, mate. We do not need to have this discussion. I thought your reply was naive, and I don't care who you are. Even Douglas Fooking I-Am-King-of-JavaScript-Land Crockford agrees that JavaScript is a functional programming language. He knows more about JavaScript than either one of us. You can keep typing in these silly boxes if you want.

Crockford is wrong. There is pretty well known.

You can keep saying wrong things if you want. Perhaps one day you'll know enough to have a laugh at yourself. It's very refreshing when you come to the realisation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment