Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-native-svg-uri

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-svg-uri

Render an SVG Image from an URL

  • 0.0.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2.4K
decreased by-20.03%
Maintainers
1
Weekly downloads
 
Created
Source

react-native-svg-uri

Render SVG images in React Native from an URL or a static file

This was tested with RN 0.33 and react-native-svg 4.3.1 (depends on this library) react-native-svg

Not all the svgs can be rendered, if you find problems fill an issue or a PR in order to contemplate all the cases

Install library from npm

npm install react-native-svg-uri --save

Link library react-native-svg

react-native link react-native-svg

Usage

Here's a simple example:

import SvgUri from 'react-native-svg-uri';

class TestSvgUri extends Component {
  render() {
    return (
      <View style={styles.container}>
         <SvgUri width="200" height="200"
                 source={{uri:'http://thenewcode.com/assets/images/thumbnails/homer-simpson.svg'}} /> 
      </View>
    );
  }
}

or a static file

 
         <SvgUri width="200" height="200"
                 source={require('./images/homer.svg')} /> 
     

This will render:

Component example

Keywords

FAQs

Package last updated on 22 Sep 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc