Is there a way to store a chart as an image directly to server using Chart.js? [closed]
Currently, I’m using html2canvas and able to first convert the chart produced using Chartjs to base64Image and then save it to a folder on the server. But, this requires me to first render the image in the browser. I want to be able to save the chart as an image without requiring it to first load on the client side. So, basically the script would run on server side and directly store the image on the server.
Advertisement
Answer
You can use https://www.image-charts.com/ with this you can send your config as as an api request and you get the image back so you will have to call this on your server to save it.