Hello everyone,
I’m developing a little one-page and I have an image grid on it. To meet the current optimization tips, I’ve set up a srcset() to get the best image according to the screen size, all automatically generated by Kirby and it’s awesome!
The concern is that this image grid contains animated gifs and these lose their animation when resized.
Here is the code in question :
<img class="object-cover w-full rounded-t" width="<?= $image->width() ?>" height="<?= $image->height() ?>" src="<?= $image->url() ?>" srcset="<?= $image->srcset([ '375w' => [width' => 305,], '768w' => [width' => 375,], '1336w' => [width' => 500,], '1500w' => [width' => 750,]]); ?>" alt="<?= $image->alt() ?> ">".
Is there a solution to this problem? Or should I think about not publishing animated gifs?
Thanks a lot!