Tag

temporary dead zone

1 views collected around this technical thread.

Tencent IMWeb Frontend Team
Tencent IMWeb Frontend Team
Sep 3, 2017 · Frontend Development

Why Does let Appear Not to Be Hoisted? Unraveling JavaScript’s Variable Lifecycle

This article chronicles the author’s two‑month journey of understanding JavaScript’s let declaration, exploring its block scope, temporal dead zone, per‑iteration bindings, and the nuanced differences from var and function hoisting, while debunking common misconceptions with code examples and spec references.

ES6JavaScriptfrontend
0 likes · 10 min read
Why Does let Appear Not to Be Hoisted? Unraveling JavaScript’s Variable Lifecycle