{"hits":[{"kind":"Guide section","title":"Leave guards (unsaved changes)","tool":"GetBrouterGuideSection(heading: \"Leave guards (unsaved changes)\")","snippet":"...use the [component-level navigation lock](#navigation-lock-blocking-from-the-component-itself) instead, which also covers parameter changes on the same route (a case `LeaveGuard`..."},{"kind":"Guide section","title":"Navigation lock: blocking from the component itself","context":"Keep-alive routes","tool":"GetBrouterGuideSection(heading: \"Navigation lock: blocking from the component itself\")","snippet":"### Navigation lock: blocking from the component itself  The lifecycle's two *pre-commit* callbacks let the routed component - the code that actually knows whether its form is dirt..."},{"kind":"Guide section","title":"Keep-alive routes","tool":"GetBrouterGuideSection(heading: \"Keep-alive routes\")","snippet":"...resume (or refresh) in `OnActivated`.  ### Navigation lock: blocking from the component itself  The lifecycle's two *pre-commit* callbacks let the routed component - the code that..."},{"kind":"Guide section","title":"Features","tool":"GetBrouterGuideSection(heading: \"Features\")","snippet":"...from `OnDeactivating` / `OnRenavigating` (React Router `useBlocker` / Vue `onBeforeRouteLeave`+`beforeRouteUpdate` style) - awaited, cancellable lock callbacks on the route lifecy..."},{"kind":"Docs page","title":"Guards & navigation locks","context":"Navigation","tool":"GetBrouterDocsPage(slug: \"guards\")","snippet":"Enter guards, preventive leave guards, component-level locks with custom dialogs, redirects and global hooks."},{"kind":"API method","title":"IBrouterRoute.OnDeactivatingAsync","context":"IBrouterRoute","tool":"GetBrouterApi(typeName: \"IBrouterRoute\")","snippet":"...re preventive: the URL never changes when the navigation is blocked. The callback may await user input (a custom \"unsaved changes\" dialog) - render the prompt, await its completion..."},{"kind":"API parameter","title":"Broute.LeaveGuard","context":"Broute","tool":"GetBrouterApi(typeName: \"Broute\")","snippet":"Async leave guard: runs when a navigation would deactivate this route (it is part of the currently rendered chain but not of the new one), before OnNavigating and any enter Broute...."},{"kind":"API method","title":"IBrouterRoute.OnRenavigatedAsync","context":"IBrouterRoute","tool":"GetBrouterApi(typeName: \"IBrouterRoute\")","snippet":"Called after a navigation re-committed this route while the same component instance stayed visible (parameter/query changes on a singleton route, or a repeated navigation to the sa..."},{"kind":"Guide section","title":"Async guards","tool":"GetBrouterGuideSection(heading: \"Async guards\")","snippet":"...et URL is never committed to history when the navigation is blocked. There is no address-bar flicker and no torn back/forward stack, and you can implement a genuine \"you have unsav..."},{"kind":"Docs page","title":"Recipes","context":"Reference","tool":"GetBrouterDocsPage(slug: \"recipes\")","snippet":"Task-oriented solutions: protected areas, unsaved changes, revalidation, switching tenant, query state, breadcrumbs, keep-alive lists."},{"kind":"API property","title":"BrouterNavigationContext.NavigationType","context":"BrouterNavigationContext","tool":"GetBrouterApi(typeName: \"BrouterNavigationContext\")","snippet":"How this navigation was initiated - a fresh push, a history-entry replace, or a Back/Forward traversal. Lets guards, loaders and hooks distinguish a Back navigation from a new push..."},{"kind":"API class","title":"BrouterRouteDeactivatingContext","tool":"GetBrouterApi(typeName: \"BrouterRouteDeactivatingContext\")","snippet":"...e preventive - the URL never changes when the navigation is blocked. This is the component-level \"navigation lock\" (React Router's useBlocker / Vue's beforeRouteLeave / Angular's C..."}],"hasMore":true}