Component docs
Loading
import { Image } from "@pixxl-tools/components";
// In Server Components:
import { Image } from "@pixxl-tools/components/server";| Prop | Type | Default | Description |
|---|---|---|---|
fit | "contain" | "cover" | "fill" | — | — |
fit"contain" | "cover" | "fill"
Other props are passed to the root element (ImgHTMLAttributes<HTMLImageElement>), including className, style, id and aria-* attributes.
const src = "/images/chart.png";
<Image src={src} alt="" />