Skip to content

Instantly share code, notes, and snippets.

@billrobbins
Created November 19, 2018 13:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save billrobbins/f2f6a1fb44e39165bf63ab340719d6bc to your computer and use it in GitHub Desktop.
Save billrobbins/f2f6a1fb44e39165bf63ab340719d6bc to your computer and use it in GitHub Desktop.
import { ActivatedRouteSnapshot, RouteReuseStrategy, DetachedRouteHandle } from '@angular/router';
export class CustomReuseStrategy implements RouteReuseStrategy {
shouldDetach(route: ActivatedRouteSnapshot): boolean {
return false;
}
store(route: ActivatedRouteSnapshot, handle: DetachedRouteHandle): boolean {
return false;
}
shouldAttach(route: ActivatedRouteSnapshot): boolean {
return false;
}
retrieve(route: ActivatedRouteSnapshot): DetachedRouteHandle {
return false;
}
shouldReuseRoute(future: ActivatedRouteSnapshot, curr: ActivatedRouteSnapshot): boolean {
return false;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment