[BUG]Crashed when using API routes as a proxy.
FriedRiceNoodles opened this issue · comments
炒米粉 commented
Describe the bug
Crashed when using API routes as a proxy like https://github.com/scottdixon/hydrogen-proxy-example.
To Reproduce
https://github.com/scottdixon/hydrogen-proxy-example
- Hydrogen version 1.6.6
- Node version 16.15.0
It looks like a bug of node-fetch
, so I console the err
then get:
This bug has appeared since 2.6.8
, and be fixed at 3.x
(they said).
(2.6.7 is OK,I tried.)
So maybe the easiest way to solve this problem is to lock the version of node-fetch
to 2.6.7
.
Why do I need to use API routes as a proxy:
Shopify/hydrogen#1724