News for hackers. Stuff that matters.
Re:What’s New in ES2019 by jacobwilliamroy on Tuesday July 30, 2019 @08:39AM (#20564248)
var and let tell the compiler the scope in which it should declare the variable (oversimplifying). If var or let are not present, the variable is declared in the global scope; unless you're in strict-mode, then you get a scolding.

So var and let are only tangential to the whole declaration process and only indicate the scope in which the variable is bound.

I feel confused. Why do you want your assignment statements to be prefixed with var's and let's?

Re:What’s New in ES2019 by z3t4 on Wednesday July 31, 2019 @07:07AM (#20573299)
if you put var in-front you don't have to worry about reassigning a variable from parent scope. You also make assignment and comparison semantically different, example var foo=1; vs foo=1 if(foo=1) and it's thus easier to spot bugs and understand the code.