Skip to content

Instantly share code, notes, and snippets.

Created December 2, 2010 19:36
Show Gist options
  • Select an option

  • Save anonymous/725911 to your computer and use it in GitHub Desktop.

Select an option

Save anonymous/725911 to your computer and use it in GitHub Desktop.
var $imgs = $('img');
$imgs.each(function(i,img){
$(new Image()).load(function(){
if (i === $imgs.length)
console.log('Carregou');
}).attr('src',img.src)
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment