Performance
Web performance from the ground up
Measure first with Core Web Vitals, then work through images, fonts, caching, bundles, React rendering and the event loop — each stop removes one reason pages are slow.
8 parts74 min readUpdated Apr 26, 2026
Parts
Part 1
Core Web Vitals: Understanding LCP, INP and CLS — and How to Fix ThemThe three metrics Google uses to measure real user experience: how they're measured and calculated, why they matter for SEO, and a concrete process to find the real cause before you fix anything.
11 min
Part 2
Image Optimization End to End: Formats, srcset, Lazy Loading and next/imageWhich format to pick, how srcset and sizes let the browser choose, when to lazy-load and when not to, reserving space to avoid CLS, image CDNs, art direction with picture, and using next/image in Next.js 16.
8 min
Part 3
Web Fonts Done Right: Fast, Stable and Correct for VietnameseHow fonts affect LCP and CLS, choosing font-display, preloading the critical font, subsetting with unicode-range for Vietnamese, variable fonts, self-hosting versus CDNs, fallback metric overrides and next/font in Next.js.
8 min
Part 4
Caching for Frontend Developers: From the HTTP Cache to CDNs and Data CachesCache-Control, ETags, hashed filenames, s-maxage and stale-while-revalidate at the CDN, service workers, staleTime in TanStack Query — what each cache layer does, which headers to set for each resource type, and the mistakes that leave users looking at stale data.
8 min
Part 5
Code Splitting and Lazy Loading in ReactA practical guide to shrinking the JavaScript you ship up front by combining route-level and component-level lazy loading.
1 min
Part 6
React Rendering Performance: Measure First, Optimize Second, and Know When to StopWhat makes a component re-render, why a re-render isn't a DOM update, how to measure with the React DevTools Profiler, the real cost of memo/useMemo/useCallback, splitting context, colocating state, keys in lists, and how the React Compiler changes the picture.
8 min
Part 7
List Virtualization from Scratch: Rendering 100,000 Rows SmoothlyBuilding a virtual list in React + TypeScript by hand: windowing math with real numbers, overscan, variable heights with prefix sums and binary search, measuring with ResizeObserver, preventing scroll jumps, accessibility — and when not to virtualize at all.
16 min
Part 8
The Event Loop, Microtasks and Rendering: Why Your UI FreezesA correct mental model of the browser event loop — tasks, microtasks, frames — tested with predict-the-output puzzles, then used to explain why UIs freeze and how to chunk work, yield to the main thread and move heavy work to a Web Worker.
14 min
Series review
0/16 answered · 0 correct
16 questions drawn from the parts of this series. Answers here count toward each post's own quiz.
Other series
Series- AI engineering for web developers4 parts · 86 min read0/4 read
- NestJS in production3 parts · 67 min read0/3 read
- Modern CSS and the web platform5 parts · 46 min read0/5 read
- Frontend architecture that lasts5 parts · 30 min read0/5 read
- The engineering craft4 parts · 21 min read0/4 read
- Frontend in depth7 parts · 129 min read0/7 read
- Business analysis for product teams6 parts · 147 min read0/6 read
- Web application security9 parts · 168 min read0/9 read