- `TanStackStartCoreOptions.ssrIsProvider` (and its copy on the Vite core
options) goes: the Rsbuild host stopped reading it, and every framework
plugin set it to "the provider environment is `ssr`", which the Vite host's
compiler state already derives from `providerEnvironmentName`;
`buildStartViteEnvironments` derives it the same way. The framework plugins
stop passing it.
- The Vite host's `clientBuilt` flag folds into `clientFiles`: null until a
client build ended in this process, then the files of its module graph in
`build --watch` (none otherwise). The server-before-client check and the
watch-mode resolver read the one field.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every Rsbuild adapter serves server fns from ssr (RSC layers the provider
into the same environment), so the third environment, its compiler entry,
dependency wiring, provider overrides and the providerEnvironmentName
option were unreachable.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
before this happened:
```
vite:hmr circular imports detected: /src/routes/posts.route.tsx -> /src/utils/posts.tsx -> /node_modules/@tanstack/react-start/dist/esm/client.js?v=0794880d -> /node_modules/@tanstack/react-start-client/dist/esm/index.js?v=0794880d -> /node_modules/@tanstack/start-client-core/dist/esm/client/index.js?v=0794880d -> /node_modules/@tanstack/start-client-core/dist/esm/client/hydrateStart.js?v=0794880d -> /src/router.tsx -> /src/routeTree.gen.ts -> /src/routes/posts.route.tsx
```
the transform of `createServerFn` imported `createClientRpc` from `@tanstack/react-start/client` which also export `hydrateStart` in index.ts
moving `createClientRpc` into its own package export resolved this issue
Removes
- react-start-server-functions-fetcher/handler/client/ssr
- solid-start-server-functions-fetcher/handler/client/ssr
Introduces (as they were called in the past)
- start-server-functions-fetcher/handler/client/ssr
The API routes only rely on h3, which is in start-server-core, so the
entire start-api-routes package can now be agnostic.
Removes
- react-start-api-routes
- solid-start-api-routes
Introduces
- start-api-routes
This PR introduce support for Solid to be used with TanStack Start.
There are several ongoing refactors that can influence the timing of
when it's most feasible to merge this.
### Status (build and run e2e/solid-start/basic)
- [X] SSR
- [x] API Routes
- [x] Server Functions
- [x] HMR
- [x] Streaming (/stream route)
- [X] Timely hydration
### Ongoing refactors
Refactor to make router packages (aka. client-only features) more
agnostic:
- #3552
- #3540
- #3538
- #3171
Refactor to make start packages (aka. server features) more agnostic:
- #3546
- #3563
- #3565
### Upstream changes to solid-router
- #3592
- #3591
- #3589
- #3616
### Passing E2E test suites
- [x] basic
- [x] website
- [x] scroll-restoration
- [x] server-functions
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Brenley Dueck <brenleydueck@gmail.com>
Co-authored-by: Iha Shin <me@xiniha.dev>
Co-authored-by: Brenley Dueck <brenley@crowdbotics.com>