post api with vuex code example

Example: posting to api with vuex

//declare the body formlet loginFormData = new FormData();//add the parametersloginFormData.set('email', state.userDetails.email);loginFormData.set('password', state.userDetails.password);const config = {    headers: {        'Content-Type': `multipart/form-data; boundary=${loginFormData._boundary}`    }};//important stepAxios.post('url', loginFormData, config)    .then(data => {        console.log(data.data);        //handle the data    })    .catch(error => {        console.log(error.response)    })