T
TanStackโ€ข3w ago
fair-rose

No `server` prop for `createFileRoute`

Hey everyone! I'm running into a strange issue. I have been using tanstack for about half a year now, mostly creating simple routes, but now I need to create an API route. Everything works well except for the fact that typescript is complaining that theres no server for createFileRoute. The api works fine - I can call it and it returns the response, its just typescript that is complaining. I am clueless why. Does anyone have any idea what to check? This is the toolkit I'm using: pnpm@10.13.1, react@19.2, clerk auth, prisma orm plus some other, non relevant libraries
Object literal may only specify known properties, and 'server' does not exist in type 'ParamsOptions<"/api/hello", ResolveParams<"/api/hello">> & FilebaseRouteOptionsInterface<Register, RootRoute<Register, undefined, { queryClient: QueryClient; }, ... 8 more ..., undefined>, ... 12 more ..., undefined> & UpdatableRouteOptions<...>'.ts(2353)
Object literal may only specify known properties, and 'server' does not exist in type 'ParamsOptions<"/api/hello", ResolveParams<"/api/hello">> & FilebaseRouteOptionsInterface<Register, RootRoute<Register, undefined, { queryClient: QueryClient; }, ... 8 more ..., undefined>, ... 12 more ..., undefined> & UpdatableRouteOptions<...>'.ts(2353)
please let me know what other information would be important to resolve the issue (I am almost certain its something obvious that I missed though ๐Ÿ˜… ). Thanks in advance! ๐Ÿ™‡โ€โ™‚๏ธ
No description
No description
2 Replies
fair-rose
fair-roseOPโ€ข3w ago
huh it looks like its about version of @tanstack/react-start. The problem does not seem to happen with version 1.134.13, but it does happen on 1.134.6. I tested out with start-basic by simply changing this package version and the typescript issue starts to happen as soon as I downgrade to 1.134.6
fair-rose
fair-roseOPโ€ข3w ago
(problem is I cannot upgrade from this version because of another issue ๐Ÿ˜… https://github.com/TanStack/router/issues/5738 )
GitHub
Some server-side modules incorrectly bundled into the client? ยท Is...
Which project does this relate to? Start Describe the bug Starting with @tanstack/react-start@1.134.7, I think server-side modules are being incorrectly bundled into the client bundle. For example,...

Did you find this page helpful?