Skip to content

Instantly share code, notes, and snippets.

View Exilz's full-sized avatar
🙃

Maxime Bertonnier Exilz

🙃
View GitHub Profile
@Exilz
Exilz / axios-interceptors-refresh-token.js
Created January 13, 2020 22:44 — forked from ModPhoenix/axios-interceptors-refresh-token.js
Axios interceptors token refresh for few async requests. ES6
import axios from 'axios';
import { settings } from '../settings';
import { authAPI } from '.';
const request = axios.create({
baseURL: settings.api_v1,
});
request.interceptors.request.use(
config => {