import { createAppRouter, type AppRouter } from "./router.ts"; let router: AppRouter | undefined; /** * The browser's single router instance. Both the pre-hydrate hook (which loads * the match tree before hydration) and must see the same instance. */ export function getClientRouter(): AppRouter { return (router ??= createAppRouter()); }