-
Notifications
You must be signed in to change notification settings - Fork 28k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding note that edge api routes are not supported with ISR #43572
Conversation
docs/basic-features/data-fetching/incremental-static-regeneration.md
Outdated
Show resolved
Hide resolved
…ion.md Co-authored-by: JJ Kasper <jj@jjsweb.site>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
@@ -27,6 +27,8 @@ description: 'Learn how to create or update static pages at runtime with Increme | |||
|
|||
Next.js allows you to create or update static pages _after_ you’ve built your site. Incremental Static Regeneration (ISR) enables you to use static-generation on a per-page basis, **without needing to rebuild the entire site**. With ISR, you can retain the benefits of static while scaling to millions of pages. | |||
|
|||
> Note: the `experimental-edge` runtime (https://nextjs.org/docs/api-reference/edge-runtime) is currently not compatible with ISR although can leverage `stale-while-revalidate` by setting the `cache-control` header manually. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this could be a bit confusing: ISR isn't just caching!
Note: The Edge Runtime is not currently compatible with ISR. Ensure you are using the default Node.js runtime with ISR.
This note is also pretty high up on the page for something I don't think most people need to know.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm yeah it's not just caching although the cache-control header provides an alternative in the mean-time while it's implemented and I don't think we want to burry this note for users who are confused by this.
We potentially could make this a build time warning instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Build time warning makes sense to me 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does "not currently compatible" look like? Will it just never update? Will it error? Will it do nothing?
Bug
fixes #number
contributing.md
Feature
fixes #number
contributing.md
Documentation / Examples
pnpm build && pnpm lint