This app demonstrates *On-Demand ISR support* in Next.js (view source).

How does this work?

When issues on the `on-demand-isr` repo change (get created, commented on, deleted, etc), GitHub fires off a webhook and the impacted pages get re-rendered and pushed to the edge, on demand. The webhook on the Next.js app side executes a new `revalidatePath()` API call.

Didn't this exist already?

Unlike `revalidate` with a time interval, a Serverless Function is invoked _only when content changes_, making it faster for the user (they see changes immediately), and more cost-efficient for owners.

_💡 Try creating a new issue or commenting, and refresh this page to see the regenerated one!_
Pages take about *300ms~* to fully propagate to the global Vercel Edge Network after the regeneration completes.

kongshu612
kongshu612 commented
No description provided.
antofa
antofa commented

test

riobuenoDevelops
riobuenoDevelops commented

test

thathurtabit
thathurtabit commented

Suup

bigyou98
bigyou98 commented

hello~

LastDray
LastDray commented

twt

thommorais
thommorais commented

ISR is more costly demanding than SSG?