score:1

Accepted answer

you can convert the values to percentage and then format the data with % and pass it to the chart. or you can use plugin like this, example

var options = {
    tooltips: {
        enabled: false
    },
    plugins: {
        datalabels: {
            formatter: (value, ctx) => {
                let sum = 0;
                let dataarr = ctx.chart.data.datasets[0].data;
                dataarr.map(data => {
                    sum += data;
                });
                let percentage = (value*100 / sum).tofixed(2)+"%";
                return percentage;
            },
            color: '#fff',
        }
    }
};

refer show percentile values in doughnutchart . happy coding!!


Related Query

More Query from same tag