v3-charts
TypeScript icon, indicating that this package has built-in type declarations

0.6.0 • Public • Published

v-charts

基于 Vue 封装的 Echarts5 图表组件

特性

  • 🔑 美观的默认样式
  • 💡 支持 vue2 和 vue3
  • ⚡️ 响应式改变尺寸
  • 📦 封装了导出表格和图片,设置单位等一些常用功能

部署

使用内网源:npm set registry http://npm.vivo.com.cn/

  1. 修改版本 (TODO 自动化)
  2. yarn build
  3. npm publish

Props

参数 说明 类型 默认值
type series.type string line
data dataSet 暂时支持一种格式 ChartData
options 传给 echart.setOption Object {}
loading 加载状态 Boolean false
unit 单位 String ''
limit 最大数量,饼图,折线图等生效 Number 0
markLine 标记 [{ yAxis: 4000, name: '标准线' }] []
sort 是否对数据排序 (只对 bar,pie 生效) Boolean false

Events

事件 说明 参数 返回值
resize 重置尺寸,同 echarts.resize
export interface ChartData<T = any> {
  columns: string[];
  rows: T[];
}

Package Sidebar

Install

npm i v3-charts

Weekly Downloads

1

Version

0.6.0

License

MIT

Unpacked Size

116 kB

Total Files

25

Last publish

Collaborators

  • dewfall