Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

设置图表配置项legend不会显示 #88

Open
huangche007 opened this issue Jul 30, 2020 · 0 comments
Open

设置图表配置项legend不会显示 #88

huangche007 opened this issue Jul 30, 2020 · 0 comments

Comments

@huangche007
Copy link

initChart(canvas, width, height) { let chart = null; chart = echarts.init(canvas, null, { width: width, height: height }); var option = { tooltip: { trigger: 'item', formatter: '{a} <br/>{b}: {c} ({d}%)' }, legend: { orient: 'vertical', right: 10, top: 20, bottom: 20, data: ['联盟广告', '视频广告', '搜索引擎'] }, series: [ { name: '访问涞源', type: 'pie', radius: ['50%', '70%'], avoidLabelOverlap: false, label: { show: false, position: 'center' }, emphasis: { label: { show: true, fontSize: '30', fontWeight: 'bold' } }, labelLine: { show: true }, data: [ {value: 234, name: '联盟广告'}, {value: 135, name: '视频广告'}, {value: 1548, name: '搜索引擎'} ] } ] }; chart.setOption(option) return chart; // 返回 chart 后可以自动绑定触摸操作 },
发现配置的legend显示不出来,"mpvue-echarts": "^0.2.7"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant