Blog
Mert Özen's blog posts on software development, backend, frontend, and DevOps.
The JavaScript Event Loop in Depth: Tasks, Microtasks and Rendering Order
We work through output-order puzzles to see the task and microtask queues, where promises and queueMicrotask fit, when requestAnimationFrame runs in the rendering step, and why long tasks freeze the page.
JavaScript OOP Patterns: Inheritance or Composition? Factory Functions and Mixins
We talk about the cost of inheritance, combining behavior with composition, factory functions and mixins, choosing between closures and #private, the SOLID principles that fit JavaScript, and when a class is worth writing.
JavaScript Object Protection and Immutability: Property Descriptors, seal and freeze
We look at property descriptors, the sneaky defaults of Object.defineProperty, the difference between preventExtensions, seal and freeze, shallow versus deep freezing, and patterns for updating objects without mutating them.
The JavaScript Prototype Chain: How Objects Inherit from Each Other
We untangle the [[Prototype]] link, property lookup along the chain, __proto__ versus Object.getPrototypeOf, constructor functions, Object.create and the prototype machinery underneath class, step by step in the console.