Dev server hot reload removes Electric API route (TanStack Start)
I have a very odd (and very minor) issue that I repeatedly run into. My workflow (using jj-vcs) involves me doing a lot of rebases or other changes to the git log.
Very often I find that when I am running the vite dev server while performing these rebase operations, the automatic route tree generated by TanStack Start/Router (I believe -
routeTree.gen.ts) will remove exactly one route from my route tree, until I restart the dev server, at which point it regenerates it back in and the file is once again unchanged.
That route is consistently the one at const ApiElectricRouteImport = createFileRoute('/api/electric')()
I have a maybe slightly complicated route structure in there, which is the only thing I can think of that might be causing it. I'm trying to take advantage of pathless routes here:
This might not be the right place for this question but I thought I'd start here since it really is only that specific route consistently, despite none of the rebased commits touching it.1 Reply
quickest-silver•4w ago
Hmm yeah not sure, best to check with the start channel