Update: In short, my problem is neither with
data-u
,data-src2
nor with any ofdata-*
attributes themselves. My problem is that usingdata-src2
attribute leaves my img tag without asrc
attribute which is a problem for w3c.
Of course it won't :) But I wonder if there is a workaround?
For the record, yes I have gone through jssor questions mentioning about w3c validation:
I am using jssor slider from jssor (I must thank him for the great work and his fast answers about the slider) with lazy loading images via data-src2
as documented in the reference page of jssor which w3 validator apparently complains about the images not having src
attribute:
Element img is missing required attribute src.
I believe pass html Validation (against w3c standards) page should contain one extra list item about validating lazy loading images. So, is there a way to work this around or should we wait for the next version as the author stated here as:
I will enhance custom attribute handling for next version. at that time, you can use "data-u" instead of "u"
Custom attribute like data-u
is w3c standard of html5. Please try html5 validation.
To make an image lazy loading, the src
attribute shouldn't be specified.
The html5 validation will raise an error for image with no src
attribute.
Actually, it doesn't matter. I'd say there is no way to fix it at the moment.