Skip to content

Instantly share code, notes, and snippets.

@DonzTea
Last active September 12, 2022 06:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DonzTea/a9df1fdaf1d3a053f3fa5e563a18a88a to your computer and use it in GitHub Desktop.
Save DonzTea/a9df1fdaf1d3a053f3fa5e563a18a88a to your computer and use it in GitHub Desktop.
axios interceptors example
import client from 'axios';
const axios = client.create({
headers: {
Accept: 'application/json',
'Content-Type': 'application/json; charset=utf-8',
},
});
export default axios;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment