-
-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
Add support for prerender:true #12010
Conversation
|
In simple "true static" sites, React Router can determine all of the static paths so there's no reason to require the app to tell us about the static paths via an array/function. This PR adds support for
prerender: true
which will walk your route tree and automatically prerender any paths that don't have dynamic/splat params.We also expose this internal logic to the function API so you can just add your own dynamic paths on top of the known static paths:
In a
routes.ts
landscape this will be nice to avoid needing to add a route in 3 places - FS,routes.ts
,prerender