perf: add defer to scripts and lazy loading to images
Some checks failed
Some checks failed
Add defer attribute to 145 <script> tags across 103 template files (PERF-067) and loading="lazy" to 22 <img> tags across 13 template files (PERF-058). Both improve page load performance. Validator totals: 0 errors, 2 warnings, 1360 info (down from 1527). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
Prerequisites:
|
||||
Add Chart.js CDN to your base template:
|
||||
<script src="https://cdn.jsdelivr.net/npm/chart.js@4.4.1/dist/chart.umd.min.js"></script>
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/chart.js@4.4.1/dist/chart.umd.min.js"></script>
|
||||
|
||||
Usage:
|
||||
{% from 'shared/macros/charts.html' import chart_card, line_chart, bar_chart, doughnut_chart %}
|
||||
|
||||
Reference in New Issue
Block a user