#510 – June 15, 2025
eliminate unnecessary re-renders
Reactivity is easy
7 minutes by Romgrk
Romgrk demonstrates how fine-grained selector-based reactivity can be achieved in just 35 lines of code, eliminating unnecessary re-renders. The solution involves creating a simple Store class that manages state and notifies components about changes, paired with a useSelector hook that allows components to subscribe only to the specific parts of state they need.
Clerk OAuth gets a big upgrade—now fully MCP-ready
sponsored by Clerk
Clerk’s latest OAuth release adds token revocation, consent screens, dynamic client registration, public client support, and full MCP compatibility. Built for modern apps and secure by default, this update makes Clerk a powerful drop-in auth solution for any OAuth use case. See what’s new and how to get started.
Use Async Local Storage to prevent props drilling in Next.js Route handlers
3 minutes by Nico Prananta
In this post Nico discuses Async Local Storage which provides an elegant solution to the problem of props drilling when handling authorized API requests. Instead of tediously passing a user object through multiple nested functions, AsyncLocalStorage creates a store accessible to all functions within the same execution context.
Search params are state
5 minutes by Tanner Linsley
Tanner advocates for treating URL search parameters as proper state in web applications rather than as an afterthought. He highlights how traditional approaches to handling search params are error-prone and lack type safety, leading to fragmentation and inconsistency. Tanner showcases how TanStack Router solves these issues by integrating search param schemas directly into route definitions, providing type inference, validation, and hierarchical inheritance of parameters.
Rebuilding Clash of Clans’ building system in React
5 minutes by Edvins Antonovs
Edvins describes recreating the core building mechanics from Clash of Clans using React and localStorage, without requiring a backend. He explains how the game's resource generation system works efficiently by tracking only timestamps and building levels rather than constantly updating resource counts, making it highly scalable.
How Imports work in RSC
22 minutes by Dan Abramov
Dan provides a deep dive for anyone who’d like to build an accurate mental model of RSC, as well as for folks who are interested in module systems in general. RSC extends JavaScript's module system to bridge the gap between frontend and backend code in a unified application. It introduces directives like 'use client' and 'use server' that allow code to reference modules from the other environment without actually importing them, creating "doors" between the two module systems.
And the most popular article from the last issue was: