firebase-tools icon indicating copy to clipboard operation
firebase-tools copied to clipboard

Support NextJS on-demand revalidation

Open jasan-s opened this issue 2 years ago • 5 comments

[REQUIRED] Environment info

firebase-tools: 11.25.3

Platform: macOS

[REQUIRED] Test case

Starting with v12.2.0, Next.js supports On-Demand Incremental Static Regeneration to manually purge the Next.js cache for a specific page. This makes it easier to update the site, however it seems firebase hosting does not detect on demand regeneration.

[REQUIRED] Steps to reproduce

Following the steps in this guide add the on demand revalidation (https://nextjs.org/docs/basic-features/data-fetching/incremental-static-regeneration#on-demand-revalidation) api path.

[REQUIRED] Expected behavior

Upon invoking the revalidation api route, the hosting should regenerate a new page.

[REQUIRED] Actual behavior

The hosting never regenerates the page matter how many time the api route is called. And the stale page remains and is continued to be served to users.

jasan-s avatar Apr 11 '23 02:04 jasan-s