If you look at the jQuery source code (or even the underfunded production version), you will see that the if (typeof value === "string" ...code branch is much more complicated than the last version elsethat will occur when passing in quantity.
1.4.4, :
} else if ( typeof value === "string" && !rnocache.test( value ) &&
(jQuery.support.leadingWhitespace || !rleadingWhitespace.test( value )) &&
!wrapMap[ (rtagName.exec( value ) || ["", ""])[1].toLowerCase() ] ) {
value = value.replace(rxhtmlTag, "<$1></$2>");
try {
for ( var i = 0, l = this.length; i < l; i++ ) {
if ( this[i].nodeType === 1 ) {
jQuery.cleanData( this[i].getElementsByTagName("*") );
this[i].innerHTML = value;
}
}
} catch(e) {
this.empty().append( value );
}
}
:
} else {
this.empty().append( value );
}
, . , if , , — , ( , , false), ( ) ...