第一步安装
npm install echartsLiquidfill --save
第二步引入
对应的vue文件:import echartsLiquidfill from 'echarts-liquidfill'
<template>
<div id='waveEchart' style="width:200px;height:200px;"></div>
</template>
<script>
import echartsLiquidfill from 'echarts-liquidfill'
mounted() {
this.initWave()
}
methods:{
initWave() {
let _this = this
let jindu
if (_this.chkValue == '0-0') {
jindu = 0.2134
}
if (_this.chkValue == '0-0-1') {
jindu = 0.4942
}
if (_this.chkValue == '0-0-2') {
jindu = 0.0146
}
setTimeout(() => {
_this.chart = this.$echarts.init(document.getElementById('waveEchart'))
// 把配置和数据放这里
_this.chart.setOption({
title: {// 标题
text: '整体进度',
textStyle: {// 标题的样式
color:
vue 水位球使用
最新推荐文章于 2024-09-20 09:33:51 发布