/** * Navigation Guard * Interface for route navigation guards */ import type { RouteConfig } from '../../api/index.js'; export type NavigationGuard = (to: RouteConfig, from: RouteConfig | null) => boolean | Promise; export interface NavigationGuardContext { /** Route being navigated to */ to: RouteConfig; /** Route being navigated from */ from: RouteConfig | null; /** Abort navigation */ abort: () => void; /** Redirect to another route */ redirect: (path: string) => void; } export type AdvancedNavigationGuard = (context: NavigationGuardContext) => void | Promise; //# sourceMappingURL=NavigationGuard.d.ts.map