1.安装echarts依赖npm install echarts --save
2.在要使用的页面引入import echarts from 'echarts'3.使用时在mounted中使用
//此时页面上的元素已经被渲染完毕 mounted() { var myChart = echarts.init(document.getElementById('echart1')); },