在vue中使用echarts做一个雷达图
效果如图
首先
1、安装echarts
npm install echarts -S
2、使用
全局使用
在main.js中
// 引入echarts
import echarts from 'echarts'
Vue.prototype.$echarts = echarts
在页面中使用
在template里面写入
<div id="leiDaTu" class="echart" style="width: 300px;height: 300px;"></div>
在script中
export default {
mounted() {
this.loadLeida()
},
methods: {
loadLeida() {
let optio