vue-mc icon indicating copy to clipboard operation
vue-mc copied to clipboard

Define global Axios configuration

Open skuhnow opened this issue 3 years ago • 1 comments

I use vue-mc with NuxtJS and Symfony as my Backend. Authentication with json_login. To make the login/auth work, I have to extend the axios config for every request with

export default function ({ $axios }) {
  $axios.onRequest((config) => {
    config.withCredentials = true

    return config
  })
}

Also, i defined the base url of my API endpoint in my NuxtJS config

axios: {
  baseURL: process.env.API_BASE_URL || 'http://local.dev:8000',
},

Both is ignored by vue-mc (although vue-mc seems to use axios internally)

skuhnow avatar Aug 25 '20 21:08 skuhnow

Maybe this one helps: https://github.com/FiguredLimited/vue-mc/issues/23

tmeisel avatar Sep 28 '20 16:09 tmeisel