I have created an <img> tag with the attributes alt, decoding, fetchpriority and loading. When NextGenImages converts the image to the WebP all of these attributes are being transfered over to the <source> element which holds the WebP image:
As per the HTML spec, this isn't allowed. The <source> HTML element only allows the media, sizes, src, srcset and type attributes. See below screenshot from the W3 HTML validator.
Would it be possible to change the NextGenImages implementation to filter out all invalid HTML attributes, thus making the HTML valid again?
I have created an
<img>
tag with the attributesalt
,decoding
,fetchpriority
andloading
. When NextGenImages converts the image to the WebP all of these attributes are being transfered over to the<source>
element which holds the WebP image:As per the HTML spec, this isn't allowed. The
<source>
HTML element only allows themedia
,sizes
,src
,srcset
andtype
attributes. See below screenshot from the W3 HTML validator.Would it be possible to change the NextGenImages implementation to filter out all invalid HTML attributes, thus making the HTML valid again?