I have been playing with ES6 for a while and I noticed that while variables declared with var are hoisted as expected… console.log(typeof name); // undefined var name =...
I understand why var takes that name – it is variable, const – it is a constant, but what is the meaning behind the name for let, which scopes...
ECMAScript 6 introduced the let statement. I’ve heard that it’s described as a local variable, but I’m still not quite sure how it behaves differently than the var keyword....