lquixada / cross-fetch

Universal WHATWG Fetch API for Node, Browsers and React Native.
MIT License
1.67k stars 104 forks source link

Error: Cannot find module 'cross-fetch' without any reason #81

Closed aeroideaservices closed 3 years ago

aeroideaservices commented 3 years ago

while running: npm install without lock file

bitworking commented 3 years ago

Same problem. For me it seems to be related to @ampproject/toolbox-optimizer.

lquixada commented 3 years ago

@aeroideaservices I couldn't reproduce this error. What are the simplest steps to do it?

bitworking commented 3 years ago

@lquixada I think it's not related to this library but some other package(s) that did a minor upgrade with a breaking change and did move cross-fetch to the peer dependencies. I could fix it by using the yarn.lock file in my dockerfile.

lquixada commented 3 years ago

got it! thanks @bitworking !