seekshiva / react-native-remote-svg

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

svg not rendering on page #19

Open atilganeren opened 5 years ago

atilganeren commented 5 years ago

I am using remote-svg on RN project. When i use svg there is no error but not rendered image to. are there some xcode optimization ? when i use svg with webview its rendering.

seekshiva commented 5 years ago

Since there is no native support for rendering svg, this project internally opens up a WebView and provides the svg via uri.

Can you provide more details about the image you are trying to load? Is it a local svg or a remote uri? If remote, can you check if the image opens correctly in a normal web browser?

Also, specifying width and height in style is mandatory (just like it is mandatory for RN Image). So make sure you specify them.

atilganeren commented 5 years ago

same code working on android and this code used to work on ios . When i install fbsdk i got binding error. i deleted node modules and run "npm install" and upgrade babel version to fix this binding error. Eventually everything works good but images has gone :(

importing like this;

import Image from 'react-native-remote-svg';

this is code;

<Image style={{
   resizeMode: "contain",
   width: wp("30%"),
   height: hp("4.05%"),
   }}
  source={require('./../../images/SVG/paketusLogo.svg')} />