15. doughnut chart
Share
- accepted / - tried
Let's create a doughnut chart in CSS.
- radius: 50px
- thickness: 10px
- color:
#f44336
The percentage should be able to set by CSS variable --percentage
.
For example, to create a doughnut chart with 20%:
<div class="piechart" style="--percentage:20%"></div>
A doughnut chart with 75%:
<div class="piechart" style="--percentage:75%"></div>