Closed conacelelena closed 4 years ago
Hello,
The calls were actually getting to the server but without the /v1 (which was replaced) and that is why I was getting the 404s. I included /v1 at the end of the origin for the api calls and it works now. I am closing this issue.
Thanks, Cristina
Hello,
I am using this buildpack to deploy my create-react-app to heroku. The deployment works alright, but the api calls to a server hosted separately don't. I followed the guidelines and created a static.json file with the following content:
{ "root": "build/", "routes": { "/**": "index.html" }, "proxies": { "/v1": { "origin": "xxx" } } }
In my redux store I have actions that call '/v1/x/' and they don't use the origin set in static.json (they use the root link). Don't know what I am missing and I would appreciate your help.
(For my development I'm using the
http-proxy-middleware
gem, since I cannot set up the proxy just for the/v1
routes in thepackage.json
).Thank you, Cristina