Home
> javascript > React – Proxy error: Could not proxy request
React – Proxy error: Could not proxy request
Problem:
I was getting the following error
“Proxy error: Could not proxy request See https://nodejs.org/api/errors.html#errors_common_system_errors for more information (ECONNREFUSED).”
Solution:
Change in package.json
"proxy": "http://localhost:5000"
To
"proxy": "http://127.0.0.1:5000"
No idea why this works. When I do a curl on localhost:5000 I get back a response. SMH. This was working previously with node version 16, but not anymore with node version 18.
Categories: javascript
nodejs, react, reactjs
Comments (0)
Trackbacks (0)
Leave a comment
Trackback