add width and height to pictures

This commit is contained in:
Fliegerjohn 2025-01-13 20:08:53 +01:00
parent 1c5631d82c
commit 9f90f3028e
Signed by: fliegerjohn
GPG key ID: E2221D5FE4656B6A

View file

@ -1,3 +1,9 @@
{{ $img := imageConfig (add "/static/" (.Destination | safeURL)) }} {{ $img := imageConfig (add "/static/" (.Destination | safeURL)) }}
<img src="{{ .Destination | safeURL }}" alt="{{ .Text }}" loading="lazy"/> <img
src="{{ .Destination | safeURL }}"
alt="{{ .Text }}"
loading="lazy"
width="{{ $img.Width }}"
height="{{ $img.Height }}"
/>