( window, noGlobal )
| 11 | // For ECMAScript module environments where a proper `window` |
| 12 | // is present, execute the factory and get jQuery. |
| 13 | function jQueryFactory( window, noGlobal ) { |
| 14 | |
| 15 | if ( typeof window === "undefined" || !window.document ) { |
| 16 | throw new Error( "jQuery requires a window with a document" ); |
| 17 | } |
| 18 | |
| 19 | var arr = []; |
| 20 | |
| 21 | var getProto = Object.getPrototypeOf; |
| 22 | |
| 23 | var slice = arr.slice; |
| 24 | |
| 25 | // Support: IE 11+ |
| 26 | // IE doesn't have Array#flat; provide a fallback. |
| 27 | var flat = arr.flat ? function( array ) { |
| 28 | return arr.flat.call( array ); |
| 29 | } : function( array ) { |
| 30 | return arr.concat.apply( [], array ); |
| 31 | }; |
| 32 | |
| 33 | var push = arr.push; |
| 34 | |
| 35 | var indexOf = arr.indexOf; |
| 36 | |
| 37 | // [[Class]] -> type pairs |
| 38 | var class2type = {}; |
| 39 | |
| 40 | var toString = class2type.toString; |
| 41 | |
| 42 | var hasOwn = class2type.hasOwnProperty; |
| 43 | |
| 44 | var fnToString = hasOwn.toString; |
| 45 | |
| 46 | var ObjectFunctionString = fnToString.call( Object ); |
| 47 | |
| 48 | // All support tests are defined in their respective modules. |
| 49 | var support = {}; |
| 50 | |
| 51 | function toType( obj ) { |
| 52 | if ( obj == null ) { |
| 53 | return obj + ""; |
| 54 | } |
| 55 | |
| 56 | return typeof obj === "object" ? |
| 57 | class2type[ toString.call( obj ) ] || "object" : |
| 58 | typeof obj; |
| 59 | } |
| 60 | |
| 61 | function isWindow( obj ) { |
| 62 | return obj != null && obj === obj.window; |
| 63 | } |
| 64 | |
| 65 | function isArrayLike( obj ) { |
| 66 | |
| 67 | var length = !!obj && obj.length, |
| 68 | type = toType( obj ); |
| 69 | |
| 70 | if ( typeof obj === "function" || isWindow( obj ) ) { |
no test coverage detected