You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: turnkey SSR via the object form of the ssr option
`ssr: {}` layers zero-config serving on top of the SSR transforms (Vite
6+): a dev middleware streams the rendered app for HTML-accepting GET
requests (Vite client + dev style patch injected, errors to the
overlay), a plain `vite build` produces client + server bundles through
the environments/builder API, and the server bundle's entry is the new
`virtual:solid-ssr-handler` whose handleRequest maps a web Request to a
streamed Response with provideRequestEvent scoping and manifest-driven
asset injection. Entries resolve conventionally with escape hatches:
explicit options, src/entry-server.* / src/entry-client.* pairs (prod
rewrites authored /src/entry-client.tsx references to the hashed
asset), else both entries are generated from a root component
(ssr.app, default src/App.*) wrapped in a document shell (ssr.document,
default src/Document.*, else a built-in one). Composes with
serverFunctions: the dev middleware runs ahead of SSR and the prod
handler serves the endpoint before rendering. Node<->web request
bridging is shared with the server-function middleware via src/http.ts,
and SSR builds now merge the persisted server-function manifest at
manifest load time so builder-mode single-invocation builds keep
client-only registrations. Adds examples/ssr-turnkey with an e2e node
suite covering dev/prod/document/entries modes (verified on Vite 6, 7,
and 8); `ssr: true` behavior is unchanged.
Co-authored-by: Cursor <cursoragent@cursor.com>
0 commit comments