0

I am working on an Angular app.

Using the APIs I get this error:

'Origin http://localhost:8000 is not allowed by Access-Control-Allow-Origin.'

I am able to use browser extensions to avoid this in Chrome and Firefox.

However, in Safari it does not have such extensions.

I also set the 'Disable local file restrictions' on the Safari browser too.

QUESTION

How do I resolve this error in Safari?

jwpfox
  • 5,124
  • 11
  • 45
  • 42
Mitch
  • 31
  • 3
  • You can avoid CORS problems by using a local server.. I like 'live-server' from npm, it refreshes the server every time you make a change to a file – Egor Egorov Mar 17 '18 at 00:41

1 Answers1

0

Seems you are trying to communicate from http (on your local app) to https and Safari blocks it. You can run your app locally also on http protocol.

Dima Dorogonov
  • 2,297
  • 1
  • 20
  • 23