我的配置如下。
var config = {
type: 'line',
data: {
labels: ["January", "February", "March", "April", "May", "June", "July"],
datasets: [{
label: "Sales",
data: [10, 20, 50, 25, 60, 12, 48],
fill: true,
lineTension: 0.25,
borderColor: "#558aeb",
backgroundColor: "#558aeb"
}]
},
options: {
responsive: true,
legend: {
display: false
},
tooltips: {
mode: 'label'
},
hover: {
mode: 'dataset'
},
scales: {
xAxes: [{
display: false
}],
yAxes: [{
display: false
}]
}
}
};