Series · 50 parts
React & Next.js Complete Guide
Modern React and the Next.js App Router: hooks, performance, server components, data fetching, forms, accessibility, testing, and production architecture.
React Fundamentals for Professionals
I've reviewed a lot of React pull requests over the years, and the bugs rarely come from exotic edge cases.
Part 1 of 50 · FrontendUnderstanding React Hooks in Depth
In React Fundamentals for Professionals I covered the mental model behind components, rendering, and the virtual DOM.
Part 2 of 50 · FrontenduseState and useReducer Patterns
In Understanding React Hooks in Depth, I covered how hooks actually work under the hood: the fiber-linked list, why call order matters, and why the rules of hooks aren't arbitrary.
Part 3 of 50 · FrontenduseEffect Without the Footguns
In the last article, we looked at useState and useReducer Patterns and how to pick the right tool for local component state.
Part 4 of 50 · FrontenduseMemo and useCallback, When They Help
The previous article in this series was about useEffect and the discipline of not reaching for it as a default tool.
Part 5 of 50 · FrontenduseRef and Working with the DOM
In useMemo and useCallback, When They Help, I went through the cases where memoization actually earns its keep and the far more common cases where it just adds noise.
Part 6 of 50 · FrontendCustom Hooks Worth Writing
In the previous article, we covered useRef and the handful of situations where reaching into the DOM directly is the right call instead of a workaround.
Part 7 of 50 · FrontendUsing React Context the Right Way
In Custom Hooks Worth Writing, I made the case for extracting logic into hooks only once you've written the same pattern three or four times, not on the first sighting of duplication.
Part 8 of 50 · FrontendReact Performance Optimization
In Using React Context the Right Way I covered how context can quietly turn into a performance problem if you put fast-changing state next to slow-changing state in the same provider.
Part 9 of 50 · FrontendAvoiding Unnecessary Re-Renders
The previous article in this series covered how to measure React performance before touching any code: the Profiler, flame charts, and the discipline of finding a real cost before optimizing
Part 10 of 50 · FrontendCode Splitting and Lazy Loading
In Avoiding Unnecessary Re-Renders, we dealt with a component tree that was already loaded but rendering more than it needed to.
Part 11 of 50 · FrontendReact Component Patterns
The previous article in this series covered how to split a bundle so users only download what a route actually needs.
Part 12 of 50 · FrontendCompound Components and Slots
In React Component Patterns I covered the props-based patterns most teams reach for first: prop drilling fixes, render props, and the classic "one giant config object" API that grows unmaint
Part 13 of 50 · FrontendError Boundaries and Suspense
In Compound Components and Slots we looked at how to give component consumers flexibility without exposing internal structure.
Part 14 of 50 · FrontendThe Next.js App Router Explained
In the last article in this series, Error Boundaries and Suspense, we looked at how React contains failure and handles asynchronous loading states at the component level.
Part 15 of 50 · FrontendServer Components in Practice
In The Next.js App Router Explained, we walked through how the App Router organizes routes, layouts, and loading states around the filesystem.
Part 16 of 50 · FrontendClient Components and When to Use Them
The previous article in this series covered Server Components: what they buy you, how data fetching changes shape, and why the App Router treats them as the default.
Part 17 of 50 · FrontendData Fetching in the App Router
In the last article we drew the line between Server Components and Client Components: what runs where, and why that boundary matters for bundle size and interactivity.
Part 18 of 50 · FrontendCaching and Revalidation in Next.js
In Data Fetching in the App Router, I covered where and how to fetch data in Server Components, Route Handlers, and Server Actions.
Part 19 of 50 · FrontendRoute Handlers and APIs in Next.js
In Caching and Revalidation in Next.js, we looked at how the framework decides what to cache and when to throw that cache away.
Part 20 of 50 · FrontendServer Actions for Mutations
In the last article, Route Handlers and APIs in Next.js, we covered when a Route Handler is the right tool: webhooks, third-party integrations, anything that needs to be called from outside
Part 21 of 50 · FrontendSEO with the Next.js Metadata API
In Server Actions for Mutations, we covered how to move writes into the App Router without hand-rolling API routes for every form.
Part 22 of 50 · FrontendRendering Strategies: SSR, SSG, and ISR
The last article in this series covered SEO with the Next.js Metadata API, and one question kept coming up without a clean answer: metadata is generated wherever the page's data comes from.
Part 23 of 50 · FrontendStyling with Tailwind CSS
The previous article in this series covered rendering strategies: when to render on the server, when to prerender at build time, and when incremental static regeneration splits the differenc
Part 24 of 50 · FrontendBuilding a UI with shadcn/ui
In Styling with Tailwind CSS I covered utility-first styling: how Tailwind's constraint-based classes keep a design system consistent without a separate CSS file per component.
Part 25 of 50 · FrontendAuthentication in Next.js
In Building a UI with shadcn/ui, the forms and dialogs we wired up assumed a logged-in user was already available somewhere in the component tree.
Part 26 of 50 · FrontendProtecting Routes with Middleware
In Authentication in Next.js I covered how to issue and store a session once a user logs in. That article stopped at the moment the cookie lands in the browser.
Part 27 of 50 · FrontendData Fetching with React Query
Once your routes are locked down with Protecting Routes with Middleware, the next problem shows up fast: every protected page needs data, and that data needs to load, refresh, and stay in sy
Part 28 of 50 · FrontendMutations and Optimistic Updates
In Data Fetching with React Query, I covered how to fetch, cache, and revalidate server state without hand-rolling loading flags for every screen. That solves the read side.
Part 29 of 50 · FrontendBuilding Forms in React
In Mutations and Optimistic Updates, I covered how to make a write feel instant: update the cache first, roll back if the server disagrees.
Part 30 of 50 · FrontendForm Validation with Zod
In Building Forms in React, I covered how to structure controlled inputs, wire up React Hook Form, and keep form state out of the render path where it doesn't belong.
Part 31 of 50 · FrontendChoosing a State Management Approach
In Form Validation with Zod, we spent a lot of effort keeping form state predictable: one schema, one source of truth for what "valid" means, and a clear boundary between what the form owns
Part 32 of 50 · FrontendZustand for Client State
In Choosing a State Management Approach, I laid out the decision tree I actually use: local state first, then Context for cross-cutting values that change rarely, then a dedicated store once
Part 33 of 50 · FrontendAccessibility in React Apps
In Zustand for Client State, I covered how to manage state that lives outside the server, modals, toasts, form drafts, without reaching for a heavier library than the problem needs.
Part 34 of 50 · FrontendKeyboard Navigation and Focus Management
In Accessibility in React Apps, I covered semantic HTML, ARIA attributes, and how screen readers interpret the DOM tree you hand them. That article treats accessibility broadly.
Part 35 of 50 · FrontendAnimations with Framer Motion
In Keyboard Navigation and Focus Management, I made the case that accessibility work is invisible when it's done right and painfully visible when it isn't.
Part 36 of 50 · FrontendCharts and Data Visualization in React
In Animations with Framer Motion, I covered how motion communicates state change: something moved, something appeared, something is loading. Charts are a different problem.
Part 37 of 50 · FrontendBuilding Tables and Data Grids
In Charts and Data Visualization in React, I looked at how to render aggregate data: totals, trends, distributions. Tables are the other half of that story.
Part 38 of 50 · FrontendTesting React Components
In Building Tables and Data Grids I covered sorting, filtering, pagination, and the state machine that keeps a data grid predictable under real usage.
Part 39 of 50 · FrontendEnd-to-End Testing with Playwright
In Testing React Components, I covered how to test components in isolation: render a piece of UI, interact with it the way a user would, and assert on what shows up.
Part 40 of 50 · FrontendAn Enterprise Folder Structure for Next.js
The last article covered end-to-end testing with Playwright, which gives the app a safety net for the flows that matter. That net doesn't fix a codebase that's hard to navigate, though.
Part 41 of 50 · FrontendBuilding a Design System
In the previous article we laid out a folder structure that scales past the "everything in components/" phase of a Next.js app.
Part 42 of 50 · FrontendDesign Tokens and Theming
The previous article in this series, "Building a Design System," covered the shape of a design system: components, variants, and the discipline of building a shared vocabulary instead of one
Part 43 of 50 · FrontendDark Mode Done Properly
In Design Tokens and Theming, I covered how to structure color, spacing, and typography as tokens instead of scattering hex values through components.
Part 44 of 50 · FrontendInternationalization (i18n) in Next.js
In Dark Mode Done Properly I covered how a seemingly small feature, theme switching, touches server rendering, hydration, and user preference storage in ways that are easy to underestimate.
Part 45 of 50 · FrontendImage and Asset Optimization
In Internationalization (i18n) in Next.js, we dealt with content that changes shape depending on who's viewing it.
Part 46 of 50 · FrontendCore Web Vitals for React Apps
In Image and Asset Optimization, we got the biggest, heaviest assets under control: images sized correctly, formats chosen deliberately, fonts loaded without blocking render.
Part 47 of 50 · FrontendError Handling and Loading States
In Core Web Vitals for React Apps, the focus was on making an app feel fast when everything goes right.
Part 48 of 50 · FrontendDeploying a Next.js App
In Error Handling and Loading States, I covered how to keep a Next.js app resilient when things go wrong at runtime.
Part 49 of 50 · FrontendA React and Next.js Production Checklist
In Deploying a Next.js App, I covered getting the app onto real infrastructure: choosing between Vercel and self-hosting, keeping Docker images lean, and handling environment variables and g
Part 50 of 50 · Frontend