News for hackers. Stuff that matters.
Re:JavaScript Isn't Scheme (2013) by mst on Wednesday April 25, 2018 @08:47PM (#16927890)
Being able to write:

    for (let x in list) {
      callbacks.push(function () { x+3 });
    }
instead of:

    for (var x in list) {
      callbacks.push((function (x) {
        function () { x + 3 }
      })(x);
    }
is a huge advantage to me. (yes, I know arrow function notation exists, but given I was explaining "why I love let" it would've been unfair to use it in the "good" example)
Re:JavaScript Isn't Scheme (2013) by Roboprog on Friday April 27, 2018 @05:39PM (#16944585)
Oh. I guess I don’t use for...in much (at all). I see your point now, though.

OTOH:

    list.forEach( function( x ) {
        callbacks.push( function () { return x + 3 } )
    }
I guess I tend to use forEach, or one of the Ramada.js operations, rather than for loops these days.

EcmaScript isn’t Scheme, or Smalltalk/Self, or Ruby. But it sucks a lot less than the other language I’m allowed to use at work :-)

(I pretend that ES is mostly Ruby)