2 Star 3 Fork 0

VisActor / VChart

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

VChart

VChart,不只是开箱即用的多端图表库,更是生动灵活的数据故事讲述者。

简介Demo教程API跨端

npm Version npm Download PRs Welcome

license

English | 简体中文

(演示视频)

简介

VChart 是 VisActor 可视化体系中的图表组件库,基于可视化语法库VGrammar 进行图表逻辑封装,基于可视化渲染引擎 VRender 进行组件封装。核心能力如下:

  1. 一码多端:自动适配桌面、H5、多个小程序环境
  2. 面向叙事:综合应用标注、动画、流程控制、叙事模板等一系列增强功能进行叙事可视化创作。
  3. 场景沉淀:面向最终用户沉淀可视化能力,解放开发者生产力

仓库简介

本仓库包含如下包:

  1. vchart:核心包,VChart 图表
  2. react-vchart:基于 React 封装的 VChart 图表组件
  3. taro-vchart:基于 Taro 封装的 VChart 图表组件
  4. lark-vchart:基于 飞书小程序 封装的 VChart 图表组件
  5. tt-vchart: 基于 抖音小程序 封装的 VChart 图表组件
  6. block-vchart:基于 飞书小组件 封装的 VChart 图表组件
  7. wx-vchart:基于 微信小程序 封装的 VChart 图表组件
  8. docs: VChart 站点源码,同时也包含站点所有的中英文文档、图表示例代码等内容。

🔨 使用

📦 安装

# npm
$ npm install @visactor/vchart

# yarn
$ yarn add @visactor/vchart

📊 一个简单的图表

import VChart from '@visactor/vchart';

const spec = {
  type: 'bar',
  data: [
    {
      id: 'barData',
      values: [
        { month: 'Monday', sales: 22 },
        { month: 'Tuesday', sales: 13 },
        { month: 'Wednesday', sales: 25 },
        { month: 'Thursday', sales: 29 },
        { month: 'Friday', sales: 38 }
      ]
    }
  ],
  xField: 'month',
  yField: 'sales',
  crosshair: {
    xField: { visible: true }
  }
};

// 'chart' 是图表 dom 容器的 id,比如 <div id="chart"></chart>
const vchart = new VChart(spec, { dom: 'chart' });
vchart.renderAsync();

⌨️ 开发

首先,全局安装 @microsoft/rush

$ npm i --global @microsoft/rush

接着将代码 clone 至本地:

# clone
$ git clone git@github.com:VisActor/VChart.git
$ cd VChart
# 安装依赖
$ rush update
# 开始 vchart 的本地开发
$ rush start
# 开始 react-vchart 的本地开发
$ rush react
# 开始站点的本地开发
$ rush docs

📖 Documents

安装并且更新依赖后,可以执行 docs 命令,开启 vchart 的本地文档预览

# start vchart document server
$ rush docs

🔗 相关链接

💫 生态

项目 介绍
React-VChart React for @VisActor/VChart

🤝 参与贡献 PRs Welcome

如想参与贡献,请先阅读行为准则贡献指南

细流成河,终成大海!

MIT License Copyright (c) 2023 Bytedance, Inc. and its affiliates. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

VChart, more than just a cross-platform charting library, but also an expressive data storyteller. 展开 收起
TypeScript 等 4 种语言
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
TypeScript
1
https://gitee.com/VisActor/VChart.git
git@gitee.com:VisActor/VChart.git
VisActor
VChart
VChart
develop

搜索帮助