xlsdg / vue-echarts-v3

Vue.js(v2.x+) component wrap for ECharts.js(v3.x+)
https://xlsdg.github.io/vue-echarts-v3-demo/
MIT License
904 stars 124 forks source link

SVG renderer for lite version? #102

Closed pjar closed 5 years ago

pjar commented 5 years ago

I want to use SVG renderer, which works fine when I use import IEcharts from 'vue-echarts-v3

But it imports everything, which is what I wanted to avoid. But when I import echarts lite:

import IEcharts from 'vue-echarts-v3/src/lite.js
import 'echarts/lib/chart/pie'
import 'echarts/lib/component/tooltip'

renderer is always canvas, despite passing proper initOpts.

How can I get SVG renderer in lite version?

pjar commented 5 years ago

OK I found out that I have to import also the following: import 'zrender/lib/svg/svg'

Would be nice to add this in the docs ;) Anyway - thank you for this great wrapper!