Skip to content
Corex

Picture

Corex\Assets\Picture · class · Core layer

Renders a <picture> for a source-controlled image (spec 062): a WebP <source> + an <img> fallback when a built .webp sibling exists next to the source on disk, else a plain <img>. This is the theme/plugin/client build-asset counterpart to Corex\Media\PictureRenderer (Media Library uploads) — it does not depend on the optional corex-media add-on.

render(string $relative, array $attrs): string

Section titled “render(string $relative, array $attrs): string”