vault-development / react-native-svg-uri

Render SVG images in React Native from an URL or static file
849 stars 334 forks source link

Problem with Rect.js "Unable to resolve module" #71

Closed kylanhurt closed 7 years ago

kylanhurt commented 7 years ago

According to the team at react-native-svg, line 3 of Rect.js needs to be changed to the following: import createReactNativeComponentClass from 'react-native/Libraries/Renderer/src/renderers/native/createReactNativeComponentClass'

image

klaaz0r commented 7 years ago

Ahh yes, had the same issue check out this PR https://github.com/matc4/react-native-svg-uri/pull/67 the problem is that the current dependencies from react-native-svg-uri do not match up with the version of react-native-svg

JavRok commented 7 years ago

+1 Please update the react-native-svg version. I had to do it manually because it was breaking my react native app. In the package.json, line 58: "dependencies": { "react-native-svg": "^4.3.1", --> CHANGE TO ^5.4.1

It works for me.

Thanks

bradstimpson commented 7 years ago

@JavRok I manually changed the dependency in the react-native-svg-uri package.json but am still getting this error. Did you make any other changes?

t4sk commented 7 years ago

npm install --save react-native-svg-uri manually change the dependency, as mentioned by @JavRok npm install again react-native link react-native-svg

did the trick for me.

JavRok commented 7 years ago

Yeah, when changing manually a version in package.json, you have to tell npm to update the node module, by running npm update I don't think what @t4sk did is necessary, but also works.

gitlovenotwar commented 7 years ago

Please update the package.json of this repo. Had to manually update.

matc4 commented 7 years ago

Fix in the last release

popaulina commented 6 years ago

@matc4 I still have this issue on the most recent version.

NickBefore commented 6 years ago

@popaulina Me too.

tobiastornros commented 6 years ago

Me too

JavRok commented 6 years ago

metoo