Interface Image

Represents an image with optional source information and alternative text.

interface Image {
    alt: string;
    src?: null | string;
    srcSet?: null | string[];
}

Properties

Properties

alt: string

The alternative text for the image, providing a textual description of the image's content. This property is required.

src?: null | string

The source URL of the image. This property is optional and can be null if no image source is provided.

srcSet?: null | string[]

An optional array of image sources for different resolutions, typically used for responsive images. Can be null if no source set is provided.