Have you tried changing your cors config settings. Of course do a config:clear afterwards.
Apr 11, 2021
5
Level 1
Axios
Hi guys, I'm trying an axios call on an external api. I can't deal with cors. I'm getting a Referrer Policy error: strict-origin-when-cross-origin. Can you advise?
axios.get(
'https://datahub.ekosystem.slovensko.digital/api/datahub/corporate_bodies/search?q=cin:' + inputValue + '&expand=rpo_organizations', {
method: 'GET',
mode: 'no-cors',
headers: {
'Access-Control-Allow-Origin': '*',
'Content-Type': 'application/json',
'Authorization': `token ${access_token}`
},
withCredentials: true,
credentials: 'same-origin',
})
Please or to participate in this conversation.