How can I effectively adjust the dimensions of a canvas element?

๐Ÿ‘:0

I found a way around it. I put the Canvas tag inside a div container with a fixed height.
Here is the code:

<div class="container" style="width: 300px;">
  <canvas id="myChart"></canvas>
</div>

Leave a comment