Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Lazy load images or delay them. Put this in the middle or end of <body> for 99.9% efficiency.
var imgs = document.getElementsByTagName('img');
var l = imgs.length;
if (l<=0) return;
var srcs = [];
for (var i=0; i<l; i++){
var img = imgs[i];
for (var i=0; i<l; i++){
imgs[i].src = srcs[i];
}, 5000);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment