anorudes / redux-easy-boilerplate

React redux easy boilerplate
MIT License
632 stars 121 forks source link

No 'Access-Control-Allow-Origin' header is present on the requested resource. #69

Closed ssmlee04 closed 8 years ago

ssmlee04 commented 8 years ago

I was making requests to my API server at http://localhost:2999 but when I try to GET /something the error message is XMLHttpRequest cannot load http://localhost:2999/currencies. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3000' is therefore not allowed access. I was wondering how to solve this issue? I tried to put headers: { "Access-Control-Allow-Origin": "*", "Access-Control-Allow-Credentials": "true" }, in webpack-dev-middleware settings but it still won't work..

oltsa commented 8 years ago

Configure your api headers - look for info exactly with that Access-Control-Allow-Origin , cors stuff have it's own kinks

2016-03-18 5:23 GMT+02:00 Shih-Min Lee notifications@github.com:

I was making requests to my API server at http://localhost:2999 but when I try to GET /something the error message is XMLHttpRequest cannot load http://localhost:2999/currencies. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3000' is therefore not allowed access. I was wondering how to solve this issue? Thanks.

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/anorudes/redux-easy-boilerplate/issues/69

oltsa commented 8 years ago

Also localhost effects cors - i have in hosts file dev.localhost routed to localhost On Mar 18, 2016 09:46, "Ollipekka Jalonen" ollipekka.jalonen@gmail.com wrote:

Configure your api headers - look for info exactly with that Access-Control-Allow-Origin , cors stuff have it's own kinks

2016-03-18 5:23 GMT+02:00 Shih-Min Lee notifications@github.com:

I was making requests to my API server at http://localhost:2999 but when I try to GET /something the error message is XMLHttpRequest cannot load http://localhost:2999/currencies. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3000' is therefore not allowed access. I was wondering how to solve this issue? Thanks.

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/anorudes/redux-easy-boilerplate/issues/69

anorudes commented 8 years ago

Hello, today the boilerplate was updated for 3 version