mirror of
https://github.com/mgerb/go-discord-bot
synced 2026-01-09 08:32:48 +00:00
15 lines
274 B
TypeScript
15 lines
274 B
TypeScript
import ax from 'axios';
|
|
|
|
export const axios = ax.create();
|
|
|
|
axios.interceptors.request.use(
|
|
config => {
|
|
// Do something before request is sent
|
|
return config;
|
|
},
|
|
function(error) {
|
|
// Do something with request error
|
|
return Promise.reject(error);
|
|
},
|
|
);
|