website-theme/layouts/partials/reading_time.html
2024-10-29 12:02:03 -04:00

9 lines
No EOL
235 B
HTML

<!-- Reading Time -->
{{ $readTime := mul (div (countwords .Content) 220.0) 60 }}
{{ if gt $readTime 60 }}
<p class="noprint">
<i class="fas fa-stopwatch"></i>
{{ math.Ceil (div $readTime 60) }} minute
reading time
</p>
{{ end }}