image
image copied to clipboard
Passing a sizes prop breaks format=null for Contentful provider in Nuxt3 RC11
Using @nuxt/image-edge with Nuxt3 RC11, when using a provider="contentful" and passing :format="null" the output works as expected:
<!-- input -->
<nuxt-img
:src="someContentfulSrc"
:format="null"
width="100"
height="100"
provider="contentful"
/>
<!-- output -->
<img src="https://...?w=100&h=100" width="100" height="100" />
But when also applying a sizes="..." prop, a format of undefined is added to the string, which breaks the image source:
<!-- input -->
<nuxt-img
:src="someContentfulSrc"
:format="null"
width="100"
height="100"
provider="contentful"
sizes="sm:100px md:200px"
/>
<!-- output -->
<img src="https://...?w=100&h=100&fm=undefined" width="100" height="100" ... />
The ?fm=undefined param is added to both the image src URL and the srcset URLs.