I am using Angular 2.1.2.
I have an authentication token (using angular2-jwt) and if it expires my webApi call fails with a 401 error. I am looking for a solution where
Ideally, the request would just 'pause' until the user logs in from the modal. I have not found a way to implement this.
Did you try to switch your button by using tokenNotExpired
attribute like in this example : https://github.com/auth0/angular2-jwt#checking-authentication-to-hideshow-elements-and-handle-routing
It allows you to prevent the 401...