I have a requirement to get a JWT from a service using an async request, and I'll need that token to set as a header in the 'request' part of the fetch-intercept pipeline here. However, since request is sync, I cannot set the token correctly unless I wait for the token to come back before running any requests. I am already able to set the token as I'm describing using an HttpInterceptor in Angular since the intercept() method they implement has the option to be a Promise.
If you could do the same, just like you already have with requestFailure and the other methods, then that would make your library a magnitude more powerful.
I have a requirement to get a JWT from a service using an async request, and I'll need that token to set as a header in the 'request' part of the fetch-intercept pipeline here. However, since request is sync, I cannot set the token correctly unless I wait for the token to come back before running any requests. I am already able to set the token as I'm describing using an HttpInterceptor in Angular since the intercept() method they implement has the option to be a Promise.
If you could do the same, just like you already have with requestFailure and the other methods, then that would make your library a magnitude more powerful.