I was looking at the axios documentation and saw that to pass the user and password it is necessary to use:
auth: {
username: 'janedoe',
password: 's00pers3cret'
},
I applied the same in my reactjs code:
axios.get(store.urlBase + 'api/teste?teste=' + teste+ '&teste2=' + teste2,{},{
auth: {
Username: 'janedoe',
Password: 's00pers3cret'
}
})
But when it arrives in api the value of username and password is empty, what can be done?
Note: By Postman it works!