Check out the following jQuery code:
if ($(this).is(':hidden')) { $(this).show(); }
My question is:
, , , - . , , , , .
, 25% . ( ) http://jsperf.com/is-hidden-check.
, , , , :
:
: jQuery 1.3.2. , , . CSS ( $(elem).css('visibility','hidden').is(':hidden') == false).
$(elem).css('visibility','hidden').is(':hidden') == false
, , . :hidden , , , 5 , , , .
:hidden
show(); , , , jQuery, -, show/: D
show()
show
your visibility check may save some effort because it will not produce .show () if it is not hidden.
So i think let's go with him