How JavaScript Runs: Engines, Memory & Execution
Peel back the runtime abstraction. Understand V8 compilation, execution contexts, call stack limits, and memory management.
A computer with a web browser or Node.js installed. No prior programming needed.
Understand how V8 interprets and compiles code, manages the call stack, and cleans memory.
Read in order, or jump to what you need.
Every lesson builds on the one before it. Open any lesson to read the explanation, run the examples, and try the practice challenges.
- 01.01The V8 Engine, JIT Compilation & The Call Stack4 min
Discover how modern JavaScript engines interpret, compile, and execute code in milliseconds using the Ignition interpreter and TurboFan compiler.
- 01.02Execution Contexts: Global, Function, and Lexical Environments4 min
Demystify execution contexts. Learn how Variable Environments, Lexical Environments, and the Creation Phase prepare your code for execution.
- 01.03Hoisting Mechanics & The Temporal Dead Zone (TDZ)4 min
Dispel the myths of hoisting. Learn how the engine handles var, let, const, and function declarations, and master the Temporal Dead Zone.
- 01.04Memory Allocation, The Heap & Mark-and-Sweep Garbage Collection4 min
Inspect the memory lifecycle. Explore primitive stack allocation, heap memory graphs, reference reachability, and V8's Mark-and-Sweep garbage collector.
Ready to move on?
Correctly predict execution order, stack frames, and TDZ boundaries across sample programs.
Open the module self-check