ma-axios.js 373 B

12345678910111213
  1. import axios from 'axios'
  2. // https://github.com/alvar0hurtad0/drupal-vuejs-todo/blob/master/frontend/src/api/axiosInterceptor.js
  3. // console.log('drupalSettings', drupalSettings);
  4. export const MA = axios.create({
  5. baseURL: window.location.origin + '/' + drupalSettings.path.pathPrefix,
  6. withCredentials: true,
  7. headers: {
  8. "Content-Type": "application/json"
  9. }
  10. })