反应图表 2https://github.com/gor181/react-chartjs-2 https://github.com/gor181/react-chartjs-2
正在引用下面
图表JShttp://www.chartjs.org/docs/#getting-started http://www.chartjs.org/docs/#getting-started
React-chartjs-2中的文档引用了chart.js文档,但它们都是错误的。我不知道如何配置反应中的图表,特别是选项。有人知道吗?
<Bar
data={{
labels: this.props.labels,
datasets: this.props.data
}}
options={{
legend: {
display: false
},
scales: {
yAxes: [{
ticks: {
max: this.props.maxY,
min: 0,
stepSize: 3
}
}]
},
title: {
display: this.props.display,
text: this.props.title
}
}}
/>
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)