-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Disable SSR (and CSR!) #231
Comments
Would an enum make this more clear so people cannot end up in impossible config states? |
What is |
Obviously you couldn't have What would the enum look like? It's easy enough to prevent impossible config states — we just throw an error |
Is it reasonable that the first steps for this feature will be
? |
To do only client-side rendering , I was thinking you'd want to skip running the kit/packages/kit/src/runtime/server/page.js Line 334 in 13f23e1
|
For this proposal I was expecting the |
Yes, I was referring only to server-side |
* documentation for ssr/router/hydrate (#231) * buncha failing tests * make ssr disable-able * implement hydrate option * prevent router from initing if router=false * make router=false work for already inited apps * implement page-level options * rename doc section * address feedback * clarify
Since this has been closed, is this now possible? How can we go about doing this? |
People often ask for SPA mode. We could do the following:
(
serverSideRendering: false
might seem nonsensical in the context of adapter-node — why not just use adapter-static? — but we might still have dynamic endpoints, so it's something that should probably work with all adapters.)Less commonly, people ask to disable client-side rendering (i.e. they just want SSR'd HTML, no interactivity) or at least client-side routing.
So we could have three new options that all default to
true
:serverSideRendering
clientSideRendering
clientSideRouting
At least one of
serverSideRendering
orclientSideRendering
would have to be true, andclientSideRouting
couldn't be false ifserverSideRendering
was false.The text was updated successfully, but these errors were encountered: