seekshiva / react-native-remote-svg

Adds support for loading svg images in React Native
MIT License
184 stars 71 forks source link

fixing iOS load issue with react native 0.56 #18

Closed virdesai closed 5 years ago

Marcsimm commented 5 years ago

When can this be merged? this is quite urgent for us

virdesai commented 5 years ago

@Marcsimm I don't have the ability to merge it otherwise I would

in the mean time, you could use this command after installing: sed -i '' 's/<WebView/<WebView originWhitelist={["*"]}/' ./node_modules/react-native-remote-svg/SvgImage.js

seekshiva commented 5 years ago

@virdesai Sorry for the delay. Can you provide more detail about how this change helps or the problem it solves?

Thanks

virdesai commented 5 years ago

@seekshiva on the current version of react-native, 0.56.0, WebView on iOS cannot load local assets without this wildcard origin whitelisting

joerichsen commented 5 years ago

I had the same problem after upgrading to 0.56 and the solution that @virdesai provides solves it 👍

The issue is described here https://github.com/facebook/react-native/issues/19986

Maybe it is the source of the problem in this issue as well? https://github.com/seekshiva/react-native-remote-svg/issues/19