[Vuejs]-I am using vue-resource with vue cli webpack i have 'Access-Control-Allow-Origin' issue

1πŸ‘

βœ…

The people who set up anotherurl.com have configured it to not allow requests via JavaScript from sites other than their own. This is a feature of HTTP / CORS.

For further reading, the Mozilla documentation explains a little more about what is going on:

https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS#Access-Control-Allow-Origin

0πŸ‘

If you are using chrome you can get an extension to ignore xframe-headers. don’t know how to solve it in production though

-1πŸ‘

I would say that as vue-resource is deprecated from 2.0 v you should look at newer API like this one here – https://github.com/mzabriskie/axios

Axios is powerful-promise based HTTP client for the browser and node.js

Leave a comment