Skip to content

Instantly share code, notes, and snippets.

@NickyYo
Created October 4, 2017 08:38
Show Gist options
  • Save NickyYo/4990e3fec2b628a6d8f7784c0bbd17bc to your computer and use it in GitHub Desktop.
Save NickyYo/4990e3fec2b628a6d8f7784c0bbd17bc to your computer and use it in GitHub Desktop.
axios.interceptors.response.use(
function(response) {
return response
},
function (error) {
if (error.response && error.response.data && error.response.data.location) {
console.log('error.response', error.response);
}
return Promise.reject(error);
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment