0👍
Try this:
function(label){
//Assuming the label.value is a number
let amount = label.value.toFixed(2);
let tooltipLabel = label.datasetLabel + ': ' + amount.replace(/(\d)(?=(\d{3})+(?!\d))/g, "$1,");
return tooltipLabel;
}
- Chartjs-Cannot find a way to correctly use chartjs annotation plugin with react
- Chartjs-Chart.Js : How to change the color of a point, based on a third data
Source:stackexchange.com