[Vuejs]-Append headers using axios intceptor

0👍

Well I figured a way to do it.. It may help others.. I am still open to better options..

axiosIntance.interceptors.request.use((config) => {
    config.headers = {'X-Some-Custom-Header': 'custom-header-value', ...config.headers} ;
    // basically the spread operator would preserve the original headers and add to it 
});

Leave a comment