- File-based routing with tanstack router
- Persist top-level navigation state in url, even for most legacy pages
- Striving for an intuitive and simple folder structure where
route-related code is colocated, but the amount of files is still
kept to a minimum
- Replace native fetch with `ky`
- Familiar api, but more polished
12 lines
373 B
TypeScript
12 lines
373 B
TypeScript
import { createFileRoute } from '@tanstack/react-router';
|
|
|
|
import { LegacyRouteController } from '@/platform/shell/route-controllers';
|
|
|
|
export const Route = createFileRoute('/$')({
|
|
component: LegacyFallbackRouteComponent,
|
|
});
|
|
|
|
function LegacyFallbackRouteComponent() {
|
|
const { _splat } = Route.useParams();
|
|
return <LegacyRouteController pathname={`/${_splat}`} />;
|
|
}
|