14 comments

[ 2.8 ms ] story [ 36.4 ms ] thread

  DOWNLOAD 
  neatshow.js 1,335 bytes
Could you find it in your heart to add two more bytes somewhere?
Sure, just slap two more bytes on it for the sake of meta.
It's not like you couldn't ensure that it got minified away or anything...
Then why bother? Do you have OCD?
The fade is lagging for me (Macbook Pro, Chrome).
Does this load in only when they are visible in the viewable area, or do they fade in everywhere?
img { opacity: 0; transition: opacity .2s; }; img.loaded { opacity: 1; };

$(function(){ $('img').load(function(){this.addClass('loaded')}) });

It works with $(this).addClass instead of this.addClass: $('img').load(function(){ $(this).addClass('loaded')});