We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
http://es6.ruanyifeng.com/#docs/let,不存在变量提升:
let foo = 'outer'; function bar(func = x => foo) { let foo = 'inner'; console.log(func()); // outer } bar();
上面的例子中, console.log()应该输出"inner"而不是"outer".
The text was updated successfully, but these errors were encountered:
traceur输出的是inner,babel输出的是outer。
inner
outer
Sorry, something went wrong.
FF 40输出的是inner.
看了一下,基本确认是 FF 的 bug。所以原文是正确的。
https://bugzilla.mozilla.org/show_bug.cgi?id=1022967 babel/babel#710
No branches or pull requests
http://es6.ruanyifeng.com/#docs/let,不存在变量提升:
上面的例子中, console.log()应该输出"inner"而不是"outer".
The text was updated successfully, but these errors were encountered: