Multithreaded problems in the single-threaded world of JavaScript
summary
Overview of how JavaScript’s single-threaded runtime handles concurrency-like problems using tools such as Web Workers and techniques that emulate multithreading. Covers practical approaches and a cheatsheet for optimizing code, and explains how React.js’s engine adapts to improve performance in complex applications.
AI-written summary · about
chapters (17)
- 0:00Introduction
- 1:31JavaScript evolution
- 3:58Event loop basics
- 8:34Race conditions
- 13:30Debouncing
- 16:21Abort controller
- 19:32Promise race
- 23:05Deadlock in JS
- 28:46Starvation prevention
- 31:14Virtualization
- 34:23Caching strategies
- 37:40React Fiber
- 43:03Fiber architecture
- 45:33Automatic batching
- 46:37Server components
- 49:23Web Workers benefits
- 52:17Closing remarks
