我想使用Chart.js在网页中创建精美的图表。
<div class="col-md-6 col-lg-3 mb-5 mb-md-3">
<div class="statcard">
<div class="p-a">
<span class="statcard-desc">Count Win Loss Trades</span>
</div>
<div>
<canvas
class="ex-graph"
width="378" height="378"
data-chart="doughnut"
data-dataset="[{{ quick_stats_trades_us['win_cnt'].tolist()|safe }}, {{ quick_stats_trades_us['loss_cnt'].tolist()|safe }}]"
data-dataset-options="{ borderColor: '#252830', backgroundColor: ['#1bc98e', '#1ca8dd'] }"
data-labels="['WIN', 'LOSE']"
style="width: 189px; height: 47px;">
</canvas>
</div>
</div>
</div>
图表未显示的原因是什么?