[Chartjs]-ToDataURL() gives checkered background to downloaded chart

1👍

This happens because it gets transformed to a PNG so it doesn’t have a background, if you want to have a background for your chart you will need to use a custom plugin to draw a big white box over the canvas before chart.js renders with a custom plugin as described here: https://www.chartjs.org/docs/master/configuration/canvas-background.html

Leave a comment