如何删除 Google 可视化折线图中的水平网格线?我已经尝试设置
minorGridlines: {count: 0 }, gridlines: {count: 0 }
在 hAxis 和 vAxis 上。
这是我的图表的一个 jsfiddle。
将
vAxis.gridlines.color
选项设置为“透明”以使其消失:
vAxis: {
gridlines: {
color: 'transparent'
}
}
在 IE 中显示时,这不适用于图表 < 9 (as those versions use VML instead of SVG, and the chart's don't support transparency in VML). In this case, you will need to set the gridline color to match the background color of the chart.
将网格线颜色设置为无
gridlines: {
color: 'none'
}
这也行
测试和工作...
options = {
vAxis: {
gridlines: {
interval: 0
}
}
}