Topic · 12 lessons in 10 series
Async and concurrency
The event loop, promises and async/await, threads and workers, and the race conditions that appear when things happen at the same time.
JavaScript CoreWhole series →
- First-Class Functions, Callbacks and Event ListenersFunctions as values: passing them as arguments, returning them from other functions, sync vs async callbacks stepped side by side, and attaching and removing event listeners without leaking memory.14 min
- Async JS and the Event LoopCall stack, Web APIs, callback queue, microtask queue and the event loop that ties them together, stepped tick by tick — plus async/await, where rendering fits, starvation, and why setTimeout(0) is not 0.20 min
System DesignWhole series →
The Browser ContractWhole series →
Backend in DepthWhole series →
Scenario DebuggingWhole series →
Senior Frontend DepthWhole series →
Full-Stack QuestionsWhole series →
Design Patterns & LLDWhole series →
JavaScript Part 2Whole series →
Node.js From ZeroWhole series →
- The Event Loop: Timers, Promises and the Poll PhaseThe loop phases, microtasks versus macrotasks, process.nextTick, setImmediate, and how a blocked loop freezes everything. Traced and run.16 min
- Concurrency: Promises, Worker Threads, Clusters and Child ProcessesPromise.all and limits, CPU work in worker_threads, cluster and why containers often replace it, and a timed comparison.16 min