enhancement: string as the default export if the preset only defines srcset
ElMassimo opened this issue ยท 0 comments
ElMassimo commented
Description ๐
Currently the default export for preset imports is ImageSource[]
. This allows presets to define additional source
tags, with different formats, conditional widths and densities, etc.
For presets that define a single ImageSource
that only contains srcsets
, it would be convenient for the default export to be a string
.
That would make it work out of the box in img
and source
tags in HTML and Vue SFCs, where src
and srcset
are already extracted as imports.