<template>
<div id="lineChart" style="width:850px;height:350px;"></div>
</template>
<script>
let eCharts = require('echarts/lib/echarts')
require('echarts/lib/chart/line')
export default {
name: 'lineChart',
mounted () {
this.initLineChart()
},
methods: {
initLineChart () {
let weatherIcons = {
Sunny: 'image://https://echarts.cdn.apache.org/examples/data/asset/img/weather/sunny_128.png',
Cloudy: 'image://https://echarts.cdn.apache.org/examples/data/asset/img/weather/cloudy_128.png',
Showers: 'image://https://echarts.cdn.apache.org/examples/data/asset/img/weather/showers_128.png'
}
let myChart = eCharts.init(document.getElementById('lineChart'))
myChart.setOption({
color: '#000',
backgroundColor: '#fff',
xAxis: {
type:
ECharts动态折线图
最新推荐文章于 2025-04-08 23:27:46 发布