Back to Nuxt

10.Nuxt Picture

docs/4.api/1.components/10.nuxt-picture.md

4.4.4638 B
Original Source

<NuxtPicture> is a drop-in replacement for the native <picture> tag.

Usage of <NuxtPicture> is almost identical to <NuxtImg> but it also allows serving modern formats like webp when possible.

Learn more about the <picture> tag on MDN.

Setup

In order to use <NuxtPicture> you should install and enable the Nuxt Image module:

bash
npx nuxt module add image

::read-more{to="https://image.nuxt.com/usage/nuxt-picture" target="_blank"} Read more about the <NuxtPicture> component. ::