Support on-demand purge nextjs cache released in 12.1 #2417
Description
Is your feature request related to a problem? Please describe.
Without the mechanism to purge the nextjs cache, it is a pitfall in production use and causing a lot of problems.
Describe the solution you'd like
Support the res.unstable_revalidate
in api which can be controlled by backend to purge the cache and regenerate the page requested. It is supported in Nextjs 12.1, and it will be great if we can support it as well:
https://nextjs.org/blog/next-12-1
Describe alternatives you've considered
Disable the next.js cache totally. To be tested. Using CDN Cache instead with a purge api call.
Additional context
An example is in this video:
https://www.youtube.com/watch?v=BGexHR1tuOA&t=16s