Nexanexa
Step 14

Optimized images

nexa build optimizes any static <img src="..."> on its own, with no developer effort: real AVIF variants, HTML rewritten to <picture>.

Nothing to declare

<img src="/photo.jpg" alt="Product" />

Any static image under public/ is detected and optimized automatically during the build.

Real result

<picture>
    <source srcset="/photo-800.avif" type="image/avif">
    <img src="/photo.jpg" alt="Product">
</picture>

The browser only downloads the smallest AVIF it needs for its viewport — never the fallback original, unless the browser doesn't support AVIF.