Skip to content

brentvatne/react-native-art-example

Repository files navigation

react-native-art-example

To use React ART on your react-native project, install react-native 0.4.2 and then npm i art --save. Add ART.xcodeproj from node_modules/react-native/React/Libraries/ART to your Libraries and link libART.a. Now you can require it:

var ReactART = require('ReactIOSART');
var {
  LinearGradient,
  RadialGradient,
  Pattern,
  Transform,
  Path,
  Surface,
  Group,
  ClippingRectangle,
  Shape,
  Text,
} = ReactART;

Check out index.ios.js to see the VectorWidget from react-art copied over and running in react-native! Pictured below but not animated because licecap was causing me some problems.

Note: This is similar to react-native-svg but much more performant for anything that animates because it doesn't pass the entire surface through SVGKit each time. You might use react-native-svg instead if you want to load a SVG image directly and not manipulate it.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published