Aimy Speed Optimization v15.0 adds support for WebP images, picture elements and srcset attributes.

Images: WebP Support

Aimy Speed Optimization now handles WebP images, allowing them to be loaded lazy or deferred.

The browser-caching rules used have been extended to handle the “image/webp” MIME type as well. Depending on your webserver’s configuration you may have to assign the MIME type to certain files depending on their extension. You can achieve this for Apache by adding the following directive:

AddType image/webp .webp

Images: picture & source Elements

Besides the common img element used to reference images in an HTML document, Aimy Speed Optimization now handles the modern and flexible picture element (that is used as a container for an image) and contained source elements as well, i.e.:

<picture>
  <source srcset="/example.webp" type="image/webp" />
  <img src="/example.jpg" alt="Fallback" width="300" height="300" />
</picture>

Images: srcset Attributes

srcset attributes are now handled by Aimy Speed Optimization on both source elements (within a picture container, see above) and img elements.