Cannot get proxy working locally.
joshuaiz opened this issue · comments
Hello,
Trying to use this to run Stripe Elements with a local React site but can't get the proxy to work.
Was following this example but updated as per the code examples in this repo to use yarn
: https://mitchgavan.com/react-serverless-shop/
Getting this error:
[HPM] Error occurred while trying to proxy request /charge from localhost:3000 to https://localhost:9000 (EPROTO) (https://nodejs.org/api/errors.html#errors_common_system_errors)
There's nothing else on port 9000. I've tried restarting both the app and lambda server and still cannot connect.
It's similar to this: #19
However none of the solutions there worked.
When I hit Submit
on my Stripe checkout form, the proxy fails and I cannot complete any transactions (running with test API keys). Is there anything specific to look for to see why the proxy is failing?
Looks like some of the code I was following from this example was out of date:
https://mitchgavan.com/react-serverless-shop/
Updated my code with more recent examples from netlify-lambda
and Stripe and it is working. I can't say exactly what did it.