zhaiduo / react-native-touchvg

TouchVG for React Native

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-native-touchvg

TouchVG for React Native

Usage

import React, { Component } from 'react';
import {View,} from 'react-native';
import { TouchVGView } from 'react-native-touchvg';

class App extends Component {

constructor(props) {
    super(props);
    this.state = {
      command: 'splines', /*Other commands:  select | erase | rect | ellipse |  triangle | line */
    }
  }

render() {
    return (
      <View style={{backgroundColor: '#fff'}}>
        <TouchVGView
          command={this.state.command}
          style={{ width: '100%', height: '100%', alignSelf: 'center' }} />
      </View>
    );
  }
}

NOTE

Based on https://github.com/rhcad/TouchVG projects.

About

TouchVG for React Native

License:MIT License


Languages

Language:C++ 50.3%Language:Java 40.7%Language:Objective-C++ 5.5%Language:Objective-C 2.1%Language:C 1.3%Language:JavaScript 0.1%