Homelogologo
Sponsor

Aspect Ratio

A component used to embed responsive videos, maps, and images while maintaining a specific aspect ratio.

Usage

The component offers a simple way to maintain a specific aspect ratio for your content.

import { AspectRatio } from "@elemnts-ui/react"
<AspectRatio ratio={16 / 9}> <img src="..." alt="..." /> </AspectRatio>

API Reference

The component accepts all div properties and the following custom props:

PropTypeDefault
rationumber | string1