Skip to content

Hanson/newline-echarts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

newline-echarts

###Introduce

许多人使用百度的echarts.js时候会出现数据名太长覆盖的情况,newline-echarts.js能够很好解决这种换行问题

###Usage

newline(option, 6, 'yAxis')

  • 参数一:是你的option
  • 参数二:是多少个字就换行
  • 参数三:是x轴还是y轴 可选项 'yAxis' OR 'xAxis'

##Example

var chart = echarts.init(document.getElementById("main"));
<script src="js/echarts.js"></script>
var option = 
{
    # your options
}

option = newline(option, 6, 'yAxis')
chart.setOption(option)

参考图片

About

echarts 换行利器

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published