Glossary term
What is TDZ (Temporal Dead Zone)?
TDZ stands for Temporal Dead Zone.
The stretch between the start of a scope and the line that declares a let or const. The name is hoisted but reading it throws a ReferenceError.
Learn it properly · JavaScript CoreLesson 8: let, const, var and the Temporal Dead ZoneThe full picture of the three declaration keywords: every axis they differ on, function scope versus block scope (and what loops do), exactly where the TDZ starts and ends and why it is temporal rather than positional, the places it hides, redeclaration, errors that stop your file before it runs, and the one exception to "typeof is always safe".