I did try to change the headers like follow
const httpOptions = {
headers: new HttpHeaders({
origin: 'https://custom.url.com',
responseType: 'text',
}),
}
console.log('here')
return new Promise((resolve, reject) => {
this._httpClient
.get(
'https://any.url.com',
httpOptions,
)
.subscribe((res) => {
console.log(res)
})
})
But I get an Refused to set unsafe header "origin"
from the browser.
Does somebody did fix the error?
The reason I want to do this, is because I'm running angular in electron, and this do not send any origin...