lquixada / cross-fetch

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

cross-fetch does not seem to work with react-native-debugger when "Enable Network Inspect" is on #71

Open rynop opened 4 years ago

rynop commented 4 years ago

https://github.com/jhen0409/react-native-debugger is a pretty popular tool to debug RN apps.

If you enable network inspect inside react-native-debugger and make a fetch() call via cross-fetch and the server responds with JSON, the response is converted to the literal string "[object Blob].

This issue has been brought up in react-native-debugger before, and the authors essentially say when this happens "you are referencing the wrong fetch". See: https://github.com/jhen0409/react-native-debugger/issues/440#issuecomment-574865959