PJPrakash Jhainblogs.prakashjha.com·Mar 26 · 3 min readThe Promise Architecture — Managing the Future of Your Code1 .What Problem Promises Actually Solve The primary enemy of a clean codebase is Inversion of Control. With callbacks, you pass a function to a third-party library and hope it calls it back correctly.00
PJPrakash Jhainblogs.prakashjha.com·Mar 26 · 3 min readAsync/Await — The "Syntactic Sugar" That Saved JSIf you’ve ever looked at a nested chain of .then() and .catch() and felt like you were reading a "Pyramid of Doom," you understand why we needed a change. Async/Await was introduced in ES2017 to make 00
PJPrakash Jhainblogs.prakashjha.com·Mar 26 · 4 min readSynchronous vs Asynchronous JavaScriptIn developer terms, we often talk about "Blocking" and "Non-blocking." But to the engine, it’s all about how we manage the Call Stack and the Task Queue. 1. What is Synchronous Code? (The "One-by-One"00
PJPrakash Jhainblogs.prakashjha.com·Mar 26 · 2 min readMap and Set in JavaScriptWhat Map is 1. The Problem with Traditional Objects We’ve used Objects as key-value stores forever. But Objects were designed to be records, not high-frequency lookup tables. Key Restrictions: Object00
PJPrakash Jhainblogs.prakashjha.com·Mar 26 · 5 min readUnderstanding the this Keyword in JavaScriptWhat this represents In JavaScript, the this keyword is a reference to the object that is currently executing the code. Its value is not fixed; instead, it is determined at runtime based on how a func00