
Flattening Arrays in JavaScript
Flatten arrays in JavaScript with flat(), recursion, stacks, depth control, compatibility notes, and performance trade‑offs for nested data safely.
Articles
This is a relatively generic and broad category where I attempt to offer guidance or instruction on more‑or‑less anything related to front‑end and web development.
Below you will find a subset of articles from my blog specifically about Guides. This is an area I have worked with for many years, and it has been a regular subject in my writing. There are three hundred thirty‑three articles collected together for you below.

Flatten arrays in JavaScript with flat(), recursion, stacks, depth control, compatibility notes, and performance trade‑offs for nested data safely.

How to write effective Angular unit tests that focus on behaviour, TestBed boundaries, realistic setup, and assertions that survive refactoring over time.

master or mainClean up local Git branches safely with commands that keep main or master, explain ‑d versus ‑D, and avoid accidental remote branch mistakes in busy repos.

Find the weekday from a JavaScript date with Date, UTC alternatives, modulo arithmetic, parsing caveats, daylight saving time, and readable day names.

instanceofUncover the differences between JavaScript's `instanceof` and `typeof` for type checking, with practical examples and insights on when to use each operator.

A practical guide to implementing authentication in Next.js with NextAuth.js, including sessions, callbacks, route protection, and router‑specific trade‑offs.

reduce() in JavaScriptUnderstand JavaScript reduce() with accumulator patterns, initial values, practical examples, readability trade‑offs, and when reduce() genuinely helps.

How to build a Progressive Web App with Angular, including service workers, caching, offline behaviour, installs, and the trade‑offs behind the defaults.

{} isn't Equal to {}In JavaScript two empty objects are not equal. One of my go‑to interviewing questions, here I offer an explanation and strategies to compare object contents.

Pure functions make JavaScript easier to test, reason about, and reuse. This guide explains what purity means and why it matters in everyday code.

The Vue 3 Composition API explained with practical TypeScript examples, refs, composables, reactivity, and when the pattern genuinely helps larger components.

Angular change detection explained through zone triggers, OnPush, signals, template cost, manual checks, and practical rendering optimisation at scale.

Validate parentheses input in TypeScript with a stack, checking bracket order, matching pairs, real parser‑style use cases, and alternative approaches.

.then() in Modern JavaScript.then() still matters in modern JavaScript. This guide explains promise chaining, return values, and why Promise.prototype.then() remains useful.

Understanding `stopPropagation` and `preventDefault` is key to handling events in JavaScript. Here, I explore their differences and when to use each.

An exploration of solutions to the 'Letter Combinations of Phone Number' problem using front‑end and TypeScript: recursion, backtracking, and iteration.

Decode the mystique of Roman numerals! Discover their structure, learn their significance, and master the art of converting them back to integers in code.

Explore the art of converting integers to Roman numerals. Dive into the ancient numeral system, grasp its structure, and master its modern‑day coding solution.