Chartjs-How can I hide points on chart?

0👍

Replace the following definition in your dataset…

pointRadius: '4',

…with the following code:

pointRadius: info.process[i].chart.map((v, index) => {
  if (index == 0 || v != info.process[i].chart[index - 1]) {
    return 4;
  }
  return 0;
}),

If you also don’t want to see the missing points on hover, do the same with pointHoverRadius: '6'.

Leave a comment