but the page which loads(homepage) needs to contact the server which needs authorization, so the page throws error (i am doing token refresh in the error block in response interceptor). Is there any way to resend the previous request again immediately, so that wont be noticable to user?
const current_path = window.location.pathname window.location.replace(current_path)
So you recommend Window history 😊
Recursion const doStuff = () => { try { ... } catch (err) { authenticate(); doStuff(); } }
I freaking HATE this refresh token + access token setup, it's just retarded
then what do you prefer?
Обсуждают сегодня