Image

Optimized image component with lazy loading, CLS prevention, responsive srcset, and fetch priority.

Basic

Lazy-loaded by default with async decoding.

Random landscape

Hero Image (Eager + High Priority)

For above-the-fold images, use eager loading with high fetch priority.

Hero banner

Object Fit

Control how the image fills its container.

Cover

Cover fit

Contain

Contain fit

Fill

Fill fit

Responsive srcset

Serve different image sizes based on viewport width.

Responsive image

Built-in Performance

  • loading="lazy" by default — only loads when entering viewport
  • decoding="async" — non-blocking image decode
  • width/height attributes prevent Cumulative Layout Shift (CLS)
  • fetchpriority="high" for LCP images
  • srcset + sizes for responsive image delivery
  • Optional blur placeholder with aspect-ratio preservation
  • Alt text is a required field — accessible by default
Open Markdown
FreeImage

Responsive image output.

Install with the Proa CLI
proa ui add image

Installs the reviewed component source, dependencies, shared support files, and required legal notices.

CLI and registry setup
recipe.rs
// SPDX-FileCopyrightText: 2026 Proa Labs, Inc.
// SPDX-License-Identifier: MIT OR Apache-2.0

//! Image recipe — typed fit/layout axes and a named placeholder slot.

use crate::tw_join;
use proa_core::shared::attr_value::AttrValue;
use proa_core::{DataLoader, WebContext, WriteBuf, WriteError};

/// Object-fit mode for the image.
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Default, proa_macros::ProaVariant)]
#[variant(name = "fit")]
pub enum ImageFit {
    #[default]
    None,
    Cover,
    Contain,
    Fill,
}

impl ImageFit {
    pub const fn classes(self) -> &'static str {

Search

Type at least 2 characters

Customize

Make it yours

Palette

Radius

Overview
Components
Settings

Build your own

Themed Proa UI surface

Preview
Components52
RecipesTyped
customer-portal