小工具知识网

当前位置: 首页 > 行业知识 > echarts中图表不清晰

行业知识

echarts中图表不清晰

2026-10-30 05:43:34 来源:互联网转载

���法1:使用svg渲染,svg渲染出的图表的清晰度高于canvas

()
var myChart = echarts.init(document.getElementById('chart'), null, {renderer: 'svg'});

方法2:仍然使用canvas渲染,通过调整devicePixelRatio提升清晰度

var myChart = echarts.init(document.getElementById('chart'), null, {devicePixelRatio: 2});

方法3:仍然使用canvas渲染,通过调整devicePixelRatio提升清晰度(vue-echarts插件)

()
 

参考:https://echarts.apache.org/zh/api.html#echarts.init

上一篇:多少台物理服务器

下一篇:英文演讲怎么greeting?