react-native-echarts

Echarts for react-native. The react-naitve chart.

  • Owner: somonus/react-native-echarts
  • Platform:
  • License:: MIT License
  • Category::
  • Topic:
  • Like:
    0
      Compare:

Github stars Tracking Chart

native-echarts

NPM Version
npm
License

install

$ npm install native-echarts --save

Usage

The Usage is complete consistent with Echarts

component props:

  • option (object): The option for echarts: Documentation
  • width (number): The width of the chart. The default value is the outer container width.
  • height (number): The height of the chart. The default value is 400.
import React, { Component } from 'react';
import {
  AppRegistry,
  StyleSheet,
  Text,
  View
} from 'react-native';
import Echarts from 'native-echarts';

export default class app extends Component {
  render() {
    const option = {
      title: {
          text: 'ECharts demo'
      },
      tooltip: {},
      legend: {
          data:['销量']
      },
      xAxis: {
          data: ["衬衫","羊毛衫","雪纺衫","裤子","高跟鞋","袜子"]
      },
      yAxis: {},
      series: [{
          name: '销量',
          type: 'bar',
          data: [5, 20, 36, 10, 10, 20]
      }]
    };
    return (
      <Echarts option={option} height={300} />
    );
  }
}

AppRegistry.registerComponent('app', () => app);

##Example

run demo

cd example
npm install
npm start

IOS

Open the xcode project in the ios directory and click run

screenshots:

image

Android

Open the Android project in the android directory with Android Studio and click run.

screenshots:

image

License

native-echarts is released under the MIT license.

Main metrics

Overview
Name With Ownersomonus/react-native-echarts
Primary LanguageHTML
Program languageJavaScript (Language Count: 5)
Platform
License:MIT License
所有者活动
Created At2016-10-21 03:03:49
Pushed At2022-04-25 20:42:05
Last Commit At2018-12-20 16:54:48
Release Count5
Last Release Name0.5.0 (Posted on )
First Release Name0.1.0 (Posted on )
用户参与
Stargazers Count721
Watchers Count21
Fork Count305
Commits Count41
Has Issues Enabled
Issues Count169
Issue Open Count124
Pull Requests Count8
Pull Requests Open Count8
Pull Requests Close Count10
项目设置
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private