3 ms·
Not according to the spec[1]: > The variables are created when their containing Lexical Environment is instantiated but may not be accessed in any way until th
by anamexis 11y ago
Not according to the spec[1]:
> The variables are created when their containing Lexical Environment is instantiated but may not be accessed in any way until the variable’s LexicalBinding is evaluated.
I.e. given a variable declared with `const`, you may not access it before it is set.
[1] http://people.mozilla.org/~jorendorff/es6-draft.html#sec-let-and-const-declarations http://people.mozilla.org/~jorendorff/es6-draft.html#sec-let...