briangonzalez / jquery.adaptive-backgrounds.js

🦎 A jQuery plugin for extracting the dominant color from images and applying the color to their parent.
http://briangonzalez.github.io/jquery.adaptive-backgrounds.js/
6.54k stars 454 forks source link

Does not work with srcset #28

Closed r3volution11 closed 9 years ago

r3volution11 commented 9 years ago

If you attempt to use this with srcset only it will spit out an error because technically there is no image src. Right now I'm providing a very low resolution version of the image in the src attribute but this means an image is downloaded twice.

r3volution11 commented 9 years ago

Please close this issue. Upon further review browsers are instructed to ignore src if a srcset is set.

jeremie-baboukhian commented 9 years ago

Is it possible to reach the srcset instead the src ?

Thx in advance