Preload Images Possible Bug
JoshWillik opened this issue · 2 comments
JoshWillik commented
You have this code to preload images:
$.preloadImages = function () {
for (var i = 0; i < arguments.length; i++) {
$('img').attr('src', arguments[i]);
}
}
If I'm not mistaken, that should set every image on the page to the last image passed, since you select all the images with $('img')
.
To create an in memory element each time, use $('<img>')
starandtina commented
Good catch!!! I think you could submit a pull request.
AllThingsSmitty commented
I fixed this when I was linting some of the snippets. Thanks.