T
TanStack13mo ago
other-emerald

Typescript error with Vite + file based routing

I upgraded all my router dependencies but receive typing errors.
No description
13 Replies
other-emerald
other-emeraldOP13mo ago
I use the router with file based routing and Vite plugin. I don't find any changelog what might could cause this.
fair-rose
fair-rose13mo ago
Make sure you are importing from @tanstack/react-router and not @tanstack/react-router/dist/...
other-emerald
other-emeraldOP13mo ago
this is the entire file.. I guess its some tsconfig setting of Typescript? But I can't really tell, I am using the latest version 5.5.4
No description
fair-rose
fair-rose13mo ago
If you can recreate this, I can probably debug this.
other-emerald
other-emeraldOP13mo ago
Im not sure how to isolate this.. is there template starter for typescript + vite + file based routing?
fair-rose
fair-rose13mo ago
StackBlitz
Router Quickstart File Based Example - StackBlitz
Run official live example code for Router Quickstart File Based, created by Tanstack on StackBlitz
other-emerald
other-emeraldOP13mo ago
thx.. i try to isolate it but no luck so far
other-emerald
other-emeraldOP13mo ago
now i did.. so it has something to do with my typescript i removed tsconfig.dev.json and ported all my tsconfig.json into the stackblitz, then immideately i see the error
other-emerald
other-emeraldOP13mo ago
No description
other-emerald
other-emeraldOP13mo ago
Is there a tsconfig section out there to see what are the minimum requirements to run the project ?
other-emerald
other-emeraldOP13mo ago
all of the examples extending a tsconfig.base.json which I dont think is actually part of the repo
No description
other-emerald
other-emeraldOP13mo ago
ahh I found it.. declaration was set to true which causes it

Did you find this page helpful?