Loading…
Loading…
Frontend · Senior full stack preparation
Protect navigation and prevent accidental loss of unsaved changes. Read practical answers and use the examples to explain your reasoning.
1 of 1 questions
CanDeactivate determines whether navigation away from the current route is allowed. Common use: warn about unsaved form changes. A guard may return a boolean, UrlTree/RedirectCommand, Promise or Observable of an allowed guard result. Client-side guards are not a substitute for server-side authorization.
Link to question 13