mirror of
https://github.com/jquery/jquery.git
synced 2026-02-17 06:42:09 -05:00
Strips IIFEs from modules; Always require built jQuery for tests.
This commit is contained in:
29
src/core.js
29
src/core.js
@@ -1,7 +1,18 @@
|
||||
var jQuery = (function() {
|
||||
// Use the correct document accordingly with window argument (sandbox)
|
||||
var document = window.document,
|
||||
navigator = window.navigator,
|
||||
location = window.location,
|
||||
|
||||
// Define a local copy of jQuery
|
||||
var jQuery = function( selector, context ) {
|
||||
// Save a reference to some core methods
|
||||
toString = Object.prototype.toString,
|
||||
hasOwn = Object.prototype.hasOwnProperty,
|
||||
push = Array.prototype.push,
|
||||
slice = Array.prototype.slice,
|
||||
trim = String.prototype.trim,
|
||||
indexOf = Array.prototype.indexOf,
|
||||
|
||||
// Define a local copy of jQuery
|
||||
jQuery = function( selector, context ) {
|
||||
// The jQuery object is actually just the init constructor 'enhanced'
|
||||
return new jQuery.fn.init( selector, context, rootjQuery );
|
||||
},
|
||||
@@ -71,14 +82,6 @@ var jQuery = function( selector, context ) {
|
||||
jQuery.ready();
|
||||
},
|
||||
|
||||
// Save a reference to some core methods
|
||||
toString = Object.prototype.toString,
|
||||
hasOwn = Object.prototype.hasOwnProperty,
|
||||
push = Array.prototype.push,
|
||||
slice = Array.prototype.slice,
|
||||
trim = String.prototype.trim,
|
||||
indexOf = Array.prototype.indexOf,
|
||||
|
||||
// [[Class]] -> type pairs
|
||||
class2type = {};
|
||||
|
||||
@@ -933,7 +936,3 @@ function doScrollCheck() {
|
||||
// and execute any waiting functions
|
||||
jQuery.ready();
|
||||
}
|
||||
|
||||
return jQuery;
|
||||
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user