Image

To use content collections for alt texts, see generateImageEntries .

---
import Image from 'fulldev-ui/components/Image.astro'
---

<Image src="placeholder-landscape.webp" />

Props

PropTypeDefault
srcstring-
position'background' | 'cover' | 'inset'-
idCollectionEntry<'images'>['id']-
HTML Attributesimg-

Examples

---
import Image from 'fulldev-ui/components/Image.astro'
---

{/* image in public/images/ */}
<Image src="/images/placeholder-landscape.webp" />

{/* optimized image in public/images/ using astro:assets */}
<Image src="/images/placeholder-landscape.webp" width={600} height={400} />

{/* automatically optimized image in src/images/ using astro:assets */}
<Image src="placeholder-landscape.webp" />