Open mquandalle opened 1 year ago
Yes it looks like pages are not statically generated during build and that would be a great addition.
Given my original intuition, I kind of expected export const prerender = true;
to still have an effect, similar to this use case.
Seeing as how I was applying ISR to a layout
, I also thought it would perhaps be possible to skip ISR for a given sub route via the inverse like export const prerender = false;
.
However, these no longer seem to have any affect when ISR is enabled for the given route.
EDIT:
It looks like if you do the following in a +page.server.js
:
export const config = { isr: false };
That cancels out the ISR configuration set at the layout level. This is useful as I want all but a few specific routes under this layout to be ISR, and adding the ISR settings to a config export for every page would be more tedious than cancelling out the few that should not be ISR. Perhaps adding a note to this effect in PR #12030 would be helpful?
Describe the bug
When my app is deployed on Vercel I expect ISR pages to be pre-rendered so that they load quickly the first time a user hit them. But it is not the case, and it's not clear how to pre-rendered them at build time.
Reproduction
https://sveltekit-isr-prerender-issue.vercel.app
Source : https://github.com/mquandalle/sveltekit-isr-prerender-issue
Logs
No response
System Info
Severity
annoyance
Additional Information
No response