Tech
Next.js App Router Caching: What Actually Gets Cached (and What Doesn't)
You deployed a Next.js App Router app, called revalidatePath() after a mutation, and the page still shows stale data. Or you disabled caching on a fetch call and the page is somehow still cached. Or you migrated from Next.js 14 to 15 and everything that was working broke silently.
All of these happen because the App Router has four separate caching layers , and they each have their own invalidation story. Developers hit these bugs constantly because the mental model of "there is one cache"...
Read the full discussion on Dev.to
This article was aggregated from Dev.to. Click to join the conversation.
View on Dev.to