optimising and making it better
This commit is contained in:
@@ -43,7 +43,8 @@ export class App implements OnInit {
|
||||
takeUntilDestroyed(this.destroyRef)
|
||||
)
|
||||
.subscribe((event) => {
|
||||
const url = (event as NavigationEnd).urlAfterRedirects || (event as NavigationEnd).url;
|
||||
const navEnd = event as NavigationEnd;
|
||||
const url = navEnd.urlAfterRedirects || navEnd.url;
|
||||
this.isHomePage.set(url === '/' || url === '/home' || url === '');
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user