mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
### What?
Execute revalidations (written into
`staticGenerationStore.{revalidatedTags,pendingRevalidates,pendingRevalidateWrites}`) that were
added during `unstable_after` callbacks.
### Why?
Previously, if `revalidatePath`/`revalidateTag` were called in an
`unstable_after` callback, nothing would happen.
I missed the fact that other codepaths (app-render, action-handler,
app-route) all [manually call
`staticGenerationStore.incrementalCache.revalidateTag`](https://github.com/vercel/next.js/blob/79f4490b0abda3fa7129c49b402dbadf6eadd79e/packages/next/src/server/app-render/app-render.tsx#L1072-L1080)
to actually perform revalidations scheduled via
`revalidatePath`/`revalidateTag`, and `after-context` wasn't doing that,
so nothing was happening.
2 lines
57 B
JavaScript
2 lines
57 B
JavaScript
export const pathPrefix = '/' + process.env.NEXT_RUNTIME
|