Lab

How JavaScript Execution Context Works

advanced
1/9

Step Explanation

Understand what is happening first

1/9

Execution Visualizer

Watch memory, stack, queues, and output

Execution Visualizer

live
Before code runs, JavaScript creates the Global Execution Context. It has memory creation phase and code execution phase.

Call Stack

1 frame
TOP ↑
Global Execution Context
frame 0
↓ BOTTOM
Global Context

Memory

0 variables

No variables in memory

Console Output

awaiting output...

varfnobjarrclosure

Code Preview

Active line 1

Code

line 1
JavaScript
Tap Expand to view full code

1/9