I imported the line component, but it's still complaining. I created my project with vue cli 3 and according to this, but I cannot find vue.config.js in my project. So I manually created vue.config.js and put it in the same folder of babel.config.js, and it broke my router.
This is my line chart:
<template>
<v-chart :options="options"/>
</template>
<script>
import ECharts from 'vue-echarts/components/ECharts'
import 'echarts/lib/chart/line'
export default {
name: 'line-chart',
components: {
'v-chart': ECharts
},
props: {
data: Object
},
data () {
return {
options: {
xAxis: {
type: 'category',
data: this.data.xAxis
},
yAxis: {
type: 'value'
},
series: [{
type: 'line',
data: this.data.values
}],
animationEasing: 'linear'
}
}
}
}
</script>