Invoke component refresh in Angular 2
问题 I am trying to implement a navbar that shows different links based on whether or not a user is logged-in. I am using the angular2-jwt library which provides the tokenNotExpired() function. I have 2 routes, /home and /login . I have a navbar component which is outside of the <router-outlet> , which means it is initialized only once and not every time the route changes. After successful login, I am invoking router.navigate(['/home]) . The home and login both have checks for if a user is logged