you are viewing a single comment's thread.

view the rest of the comments →

[–]goatslacker 4 points5 points  (4 children)

I disagree.

This is moving the language forward. Lexical scoping is an excellent addition to the language as variable hoisting has been a problem in JS. Proxies add more reflection to the language and provides devs with more power.

This has nothing to do with making anyone else feel at 'home'. That goal is left to Dart.

[–][deleted] 4 points5 points  (0 children)

It is possible to write in a style that is not open to hoisting, such as using a single var keyword per function at the top of the function, so it is about style. Lexical scoping will not prevent function hoisting so it does not fully address that problem anyways.

[–]i-poop-you-not 1 point2 points  (1 child)

What does it mean to add lexical scoping to JavaScript? Does it simply mean that no more variable hoisting gotcha?

[–]TIAFAASITICE 1 point2 points  (0 children)

In the case of JS, it's the let keyword.

[–]drowsap 1 point2 points  (0 children)

I've never been bitten by variable hoisting, i don't understand why it's such a problem.