You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We use this library at Walmart. And now we're trying to use it within our React Native codebase, but unfortunately, it's not working there due to isomorphic-fetch, which is not compatible with React Native.
One way to solve the problem is to modify the package.json of redux-effects-fetch and map isomorphic-fetch to a stub file that basically does nothing (since React Native doesn't need a fetch polyfill).
So, the package.json would be modified to include the following
And the content of rn-isomorphic-fetch.js would simply be:
exportdefault{}
...and by doing that, we fix redux-effects-fetch for React Native apps.
This change would only affect React Native apps because only React Native Packager cares about the react-native key in package.json. webpack and other bundlers ignore this key.
If I send a PR with these changes, would you be able to merge it and publish a new version?
Thanks a lot!
MK
The text was updated successfully, but these errors were encountered:
Hi,
We use this library at Walmart. And now we're trying to use it within our React Native codebase, but unfortunately, it's not working there due to
isomorphic-fetch
, which is not compatible with React Native.One way to solve the problem is to modify the
package.json
ofredux-effects-fetch
and mapisomorphic-fetch
to a stub file that basically does nothing (since React Native doesn't need afetch
polyfill).So, the
package.json
would be modified to include the followingAnd the content of
rn-isomorphic-fetch.js
would simply be:...and by doing that, we fix
redux-effects-fetch
for React Native apps.This change would only affect React Native apps because only React Native Packager cares about the
react-native
key inpackage.json
. webpack and other bundlers ignore this key.If I send a PR with these changes, would you be able to merge it and publish a new version?
Thanks a lot!
MK
The text was updated successfully, but these errors were encountered: