Hi,
How can you explain that “$src” in {{ $loading := (dict "url" $img.Permalink "srcset" $src "sizes" $Sizes) }}, when used in the image renderhook produces a correct responsive img tag, but when used for
You can see what’s wrong, when the corresponding img tag (generated with the same $src Scratch or Store variable, is:
<img src="../Images/memes/chad_traditional_food_preparing_woman_huf4a3b88d4f7fd1d0f818e258fbbd887d_904442_800x0_resize_q95_h2_lanczos_2.webp" srcset="http://localhost:1313/Images/memes/chad_traditional_food_preparing_woman_huf4a3b88d4f7fd1d0f818e258fbbd887d_904442_800x0_resize_q95_h2_lanczos_2.webp 800w, http://localhost:1313/Images/memes/chad_traditional_food_preparing_woman_huf4a3b88d4f7fd1d0f818e258fbbd887d_904442_500x0_resize_q95_h2_lanczos_2.webp 500w, http://localhost:1313/Images/memes/chad_traditional_food_preparing_woman_huf4a3b88d4f7fd1d0f818e258fbbd887d_904442_318x0_resize_q95_h2_lanczos_2.webp 318w, http://localhost:1313/Images/memes/chad_traditional_food_preparing_woman_huf4a3b88d4f7fd1d0f818e258fbbd887d_904442_200x0_resize_q95_h2_lanczos_2.webp 200w" loading="eager" fetchpriority="high" alt="Parodic modification of a meme normally praising traditional gender role and cooking, to promote instead innate ape&rsquo;s superior strength acquired with raw food" title="Men on the other hand, are known to lose muscles without constant exercising." sizes="(max-width: 350px) 100vw, (max-width: 600px) 100vw, 70vw" width="800px" height="453px">
Thanks, but God… I thought the parameters in the config file allowed to bypass that kind of security check ? Or is it a stop-gap measure ? I didn’t have that problem before.
I don’t know… I just wonder what happened. Before I was pleased not having to use this ugly syntax, and now I have to ? What happened in this version ?
From the above, it looks like you are using the value in two different attributes: srcset and imagesrcset. The Go issue I referenced above is about the imagesrcset attribute (i.e., it behaves differently than srcset).
yes, exactly, it behaves differently… why ? They’re both templates, I don’t understand. is it a matter of which template it is in ? html-head.html vs render-image.html, or different attributes (or different attributes of different tags) being treated differently despite having the same exact value ?
I did and I see nothing like an explanation… not for a non-developer at least. That sentence is the closest to answer. To me it basically just reads like “yeah it doesn’t work”
yes, people have no sense of edgy humor. Oh hell.
Thank you so that is what I changed… in the config. I have difficulty keeping track of everything, so things like that happen.