Prerender same page multiple times
Unanswered
Australian Terrier posted this in #help-forum
Australian TerrierOP
I have an app with some middleware that rewrites reqeusts to the same underlying page. The pathnames
-
-
-
all get rewritten to
I know at build-time which pathnames will cause
I know that the middleware would still be needed for routing during production, but there is no reason to actually re-run the render logic for each request since that can all happen at build-time.
-
/page-1-
/page-2-
/page-3all get rewritten to
/page, so src/app/page/page.tsx get's rendered for all three.I know at build-time which pathnames will cause
/page to render. The page will appear differently depending on which pathname is used. Is there a way to statically build the page multiple times without adding a route-parameter? I know that the middleware would still be needed for routing during production, but there is no reason to actually re-run the render logic for each request since that can all happen at build-time.