Chartjs is love
by durlavk
Creating charts is gonna be my new thing π»π.
As I mentioned I was trying to include charts in a laravel project. The laravel package made using chartjs was not properly working for some reason. So, I went and tried chartjs and I loved it.
Normally I donβt like to include js in a laravel project unless itβs necessary. But using chartjs was very easy. I am using it through the cdn and it works fine. The chartsjs library is pretty neat. To introduce a chart just add a canvas
element and in js get the element by id and get itβs context similar to how canvas is normally used. The fun starts in Chart()
function. There you can specify the chart type, give itβs data and tweak with itβs color/border and axis options. I would definitely recommend using it for any charts you may want to show in your site.