DEV Community

Discussion on: 3 reasons to use 'var' in JavaScript

Collapse
 
koire profile image
Koire

Don't forget code golf!
Let's scope is more constrained than var, so you (maybe) can't do as many tricks with let as var.
And const is 2 more characters! That's unforgivable

Collapse
 
paritho profile image
Paul Thompson

There are actually a lot of really cool exploits you can do in JS because of it. Golf coding is amazing!