MCPcopy Create free account
hub / github.com/PrairieLearn/PrairieLearn / isArraylike

Function isArraylike

public/localscripts/calculationQuestion/jquery.js:848–863  ·  view source on GitHub ↗
( obj )

Source from the content-addressed store, hash-verified

846});
847
848function isArraylike( obj ) {
849 var length = obj.length,
850 type = jQuery.type( obj );
851
852 if ( jQuery.isWindow( obj ) ) {
853 return false;
854 }
855
856 if ( obj.nodeType === 1 && length ) {
857 return true;
858 }
859
860 return type === "array" || type !== "function" &&
861 ( length === 0 ||
862 typeof length === "number" && length > 0 && ( length - 1 ) in obj );
863}
864
865// All jQuery objects should point back to these
866rootjQuery = jQuery(document);

Callers 1

jquery.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected