vue-auth-plugin
vue-auth-plugin copied to clipboard
[FEATURE REQUEST] - Refresh Token
trafficstars
It would be great if one could get a refresh token together with the initial access token in the login response payload - an enhancement to https://github.com/d0whc3r/vue-auth-plugin/pull/80.
Example:
{
"token": "eyJ************KJU",
"refreshToken": "ed******************WjT",
"type": "bearer"
}
The refreshToken is then stored in a separate key in localstorge (or cookie/vuex).
If the refreshData option fires, or with $auth.refresh() method, the API call will then include the refreshToken in the Authorization header or the request body.
Your thoughts?