Created
November 10, 2018 14:07
-
-
Save nathan-lapinski/8f0ea3b16a70428a20bb3ae056f4b74d to your computer and use it in GitHub Desktop.
preloading on nav
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
setUpPreloading(): void { | |
this.subscription = | |
this.router.events | |
.pipe(filter((e: Event) => e instanceof NavigationEnd), concatMap(() => this.preload())) | |
.subscribe(() => {}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment