Debounce vs Throttle — One Sentence to Remember Forever
Two patterns for taming fast events: debounce waits for silence, throttle limits how often. With examples, code, and interview answers.
Short posts with code and diagrams. Readable in minutes.
Two patterns for taming fast events: debounce waits for silence, throttle limits how often. With examples, code, and interview answers.
`||` treats 0 and '' as missing. `??` only treats null/undefined as missing. Know the difference before it bites you in an interview or in prod.
Generators let you produce values on demand instead of all at once. Learn how iterators and generator functions work, and when to reach for them.
What queueMicrotask does, how it differs from Promise.then, and how microtasks really work under the hood.
Async/await feels like parallel code, but it isn’t. Here’s why JavaScript is still single-threaded and how async really works.
If JavaScript is single-threaded, how can Promise.all handle multiple requests at the same time? A deep dive into the event loop and async I/O.
A practical and conceptual comparison of Promise.all, Promise.race, Promise.any, and Promise.allSettled.
How Web Workers work, why they matter, and when to use them to achieve real parallelism in frontend apps.