jQuery 3.0 Final Released!

Posted on by

jQuery 3.0 is now released! This version has been in the works since October 2014. We set out to create a slimmer, faster version of jQuery (with backwards compatibility in mind). We’ve removed all of the old IE workarounds and taken advantage of some of the more modern web APIs where it made sense. It is a continuation of the 2.x branch, but with a few breaking changes that we felt were long overdue. While the 1.12 and 2.2 branches will continue to receive critical support patches for a time, they will not get any new features or major revisions. jQuery 3.0 is the future of jQuery. If you need IE6-8 support, you can continue to use the latest 1.12 release.

Despite the 3.0 version number, we anticipate that these releases shouldn’t be too much trouble when it comes to upgrading existing code. Yes, there are a few “breaking changes” that justified the major version bump, but we’re hopeful the breakage doesn’t actually affect that many people.

To assist with upgrading, we have a brand new 3.0 Upgrade Guide. And the jQuery Migrate 3.0 plugin will help you to identify compatibility issues in your code. Your feedback on the changes will help us greatly, so please try it out on your existing code and plugins!

You can get the files from the jQuery CDN, or link to them directly:

https://code.jquery.com/jquery-3.0.0.js

https://code.jquery.com/jquery-3.0.0.min.js

You can also get the release from npm:

npm install jquery@3.0.0

In addition, we’ve got the release for jQuery Migrate 3.0. We highly recommend using this to address any issues with breaking changes in jQuery 3.0. You can get those files here:

https://code.jquery.com/jquery-migrate-3.0.0.js

https://code.jquery.com/jquery-migrate-3.0.0.min.js

npm install jquery-migrate@3.0.0

For more information about upgrading your jQuery 1.x and 2.x pages to jQuery 3.0 with the help of jQuery Migrate, see the jQuery Migrate 1.4.1 blog post.

Slim build

Finally, we’ve added something new to this release. Sometimes you don’t need ajax, or you prefer to use one of the many standalone libraries that focus on ajax requests. And often it is simpler to use a combination of CSS and class manipulation for all your web animations. Along with the regular version of jQuery that includes the ajax and effects modules, we’re releasing a “slim” version that excludes these modules. All in all, it excludes ajax, effects, and currently deprecated code. The size of jQuery is very rarely a load performance concern these days, but the slim build is about 6k gzipped bytes smaller than the regular version – 23.6k vs 30k. These files are also available in the npm package and on the CDN:

https://code.jquery.com/jquery-3.0.0.slim.js

https://code.jquery.com/jquery-3.0.0.slim.min.js

This build was created with our custom build API, which allows you to exclude or include any modules you like. For more information, have a look at the jQuery README.
 

Compatibility with jQuery UI and jQuery Mobile

While most things will work, there are a few issues that jQuery UI and jQuery Mobile will be addressing in upcoming releases. If you find an issue, keep in mind that it may already be addressed upstream and using the jQuery Migrate 3.0 plugin should fix it. Expect releases soon.

 

Major changes

Below are just the highlights of the major new features, improvements, and bug fixes in these releases, you can dig into more detail on the 3.0 Upgrade Guide. A complete list of issues fixed is available on our GitHub bug tracker. If you read the blog post for 3.0.0-rc1, the below features are the same.

jQuery.Deferred is now Promises/A+ compatible

jQuery.Deferred objects have been updated for compatibility with Promises/A+ and ES2015 Promises, verified with the Promises/A+ Compliance Test Suite. This meant we needed some major changes to the .then() method. Legacy behavior can be restored by replacing any use of .then() with the now-deprecated .pipe() method (which has an identical signature).

  1. An exception thrown in a .then() callback now becomes a rejection value. Previously, exceptions bubbled all the way up, aborting callback execution. Any deferreds relying on the resolution of the deferred that threw an exception would never have resolved.

  2. Example: uncaught exceptions vs. rejection values

    
    var deferred = jQuery.Deferred();
    deferred.then(function() {
      console.log("first callback");
      throw new Error("error in callback");
    })
    .then(function() {
      console.log("second callback");
    }, function(err) {
      console.log("rejection callback", err instanceof Error);
    });
    deferred.resolve();
    

    Previously, “first callback” was logged and the error was thrown. All execution was stopped. Neither “second callback” nor “rejection callback” would have been logged. The new, standards-compliant behavior is that you’ll now see “rejection callback” and true logged. err is the rejection value from the first callback.


  3. The resolution state of a Deferred created by .then() is now controlled by its callbacks—exceptions become rejection values and non-thenable returns become fulfillment values. Previously, returns from rejection handlers became rejection values.

  4. Example: returns from rejection callbacks

    
    var deferred = jQuery.Deferred();
    deferred.then(null, function(value) {
      console.log("rejection callback 1", value);
      return "value2";
    })
    .then(function(value) {
      console.log("success callback 2", value);
      throw new Error("exception value");
    }, function(value) {
      console.log("rejection callback 2", value);
    })
    .then(null, function(value) {
      console.log("rejection callback 3", value);
    });
    deferred.reject("value1");
    

    Previously, this would log “rejection callback 1 value1”, “rejection callback 2 value2”, and “rejection callback 3 undefined”.

    The new, standards-compliant behavior is that this will log “rejection callback 1 value1”, “success callback 2 value2″, and “rejection callback 3 [object Error]”.


  5. Callbacks are always invoked asynchronously, even if a Deferred has already been resolved. Previously, these callbacks were executed synchronously upon binding.

  6. Example: async vs sync

    
    var deferred = jQuery.Deferred();
    deferred.resolve();
    deferred.then(function() {
      console.log("success callback");
    });
    console.log("after binding");
    

    Previously, this would log “success callback” then “after binding”. Now, it will log “after binding” and then “success callback”.


Important: while caught exceptions had advantages for in-browser debugging, it is far more declarative (i.e. explicit) to handle them with rejection callbacks. Keep in mind that this places the responsibility on you to always add at least one rejection callback when working with promises. Otherwise, some errors might go unnoticed.

We’ve built a plugin to help in debugging Promises/A+ compatible Deferreds. If you are not seeing enough information about an error on the console to determine its source, check out the jQuery Deferred Reporter Plugin.

jQuery.when has also been updated to accept any thenable object, which includes native Promise objects.

https://github.com/jquery/jquery/issues/1722
https://github.com/jquery/jquery/issues/2102

Added .catch() to Deferreds

The catch() method was added to promise objects as an alias for .then(null, fn).

https://github.com/jquery/jquery/issues/2102

Error cases don’t silently fail

Perhaps in a profound moment you’ve wondered, “What is the offset of a window?” Then you probably realized that is a crazy question – how can a window even have an offset?

In the past, jQuery has sometimes tried to make cases like this return something rather than having them throw errors. In this particular case of asking for the offset of a window, the answer up to now has been { top: 0, left: 0 } With jQuery 3.0, such cases will throw errors so that crazy requests aren’t silently ignored. Please try out this release and see if there is any code out there depending on jQuery to mask problems with invalid inputs.

https://github.com/jquery/jquery/issues/1784

Removed deprecated event aliases

.load, .unload, and .error, deprecated since jQuery 1.8, are no more. Use .on() to register listeners.

https://github.com/jquery/jquery/issues/2286

Animations now use requestAnimationFrame

On platforms that support the requestAnimationFrame API, which is pretty much everywhere but IE9 and Android<4.4, jQuery will now use that API when performing animations. This should result in animations that are smoother and use less CPU time – and save battery as well on mobile devices.

jQuery tried using requestAnimationFrame a few years back but there were serious compatibility issues with existing code so we had to back it out. We think we’ve beaten most of those issues by suspending animations while a browser tab is out of view. Still, any code that depends on animations to always run in nearly real-time is making an unrealistic assumption.

Massive speedups for some jQuery custom selectors

Thanks to some detective work by Paul Irish at Google, we identified some cases where we could skip a bunch of extra work when custom selectors like :visible are used many times in the same document. That particular case is up to 17 times faster now!

Keep in mind that even with this improvement, selectors like :visible and :hidden can be expensive because they depend on the browser to determine whether elements are actually displaying on the page. That may require, in the worst case, a complete recalculation of CSS styles and page layout! While we don’t discourage their use in most cases, we recommend testing your pages to determine if these selectors are causing performance issues.

This change actually made it into 1.12/2.2, but we wanted to reiterate it for jQuery 3.0.

https://github.com/jquery/jquery/issues/2042

As mentioned above, the Upgrade Guide is now available for anyone ready to try out this release. Aside from being helpful in upgrading, it also lists more of the notable changes.

 

Thanks

Thank you to everyone who helped with this release through code contributions, issue reports, and more, including but not limited to Jason Bedard, Fredrik Blomqvist, Leonardo Braga, Ralin Chimev, Jon Dufresne, Oleg Gaidarenko, Richard Gibson, Michał Gołębiowski, Scott González, Zack Hall, Alexander K, Martijn W. van der Lee, Alexander Lisianoi, Steve Mao, Dave Methvin, Jha Naman, Jae Sung Park, Todor Prikumov, William Robinet, Felipe Sateler, Damian Senn, Josh Soref, Jun Sun, Christophe Tafani-Dereeper, Vitaliy Terziev, Joe Trumbull, Bernhard M. Wiedemann, Devin Wilson, and Henry Wong.

 

Changelog

Ajax

  • Golf away 21 bytes (eaa3e9f)
  • Preserve URL hash on requests (#1732, e077ffb)
  • Execute jQuery#load callback with correct context (#3035, 5d20a3c)
  • Ensure ajaxSettings.traditional is still honored (#3023, df2051c)
  • Remove unnecessary use of jQuery.trim (0bd98b1)

Attributes

  • Avoid infinite recursion on non-lowercase attribute getters (#3133, e06fda6)
  • Add a support comment & fix a link @ tabIndex hook (9cb89bf)
  • Strip/collapse whitespace for set values on selects (#2978, 7052698)
  • Remove redundant parent check (b43a368)
  • Fix setting selected on an option in IE<=11 (#2732, 780cac8)

CSS

  • Don’t workaround the IE 11 iframe-in-fullscreen sizing issues (#3041, ff1a082)
  • Toggle detached elements as visible unless they have display: none (#2863, 755e7cc)
  • Make sure elem.ownerDocument.defaultView is not null (#2866, 35c3148)
  • Add animation-iteration-count to cssNumber (#2792, df822ca)
  • Restore cascade-override behavior in .show (#2654, #2308, dba93f7)
  • Stop Firefox from treating disconnected elements as cascade-hidden (#2833, fe05cf3)

Core

Deferred

  • Separate the two paths in jQuery.when (#3029, 356a3bc)
  • Provide explicit undefined context for jQuery.when raw casts (#3082, 7f1e593)
  • Remove default callback context (#3060, 7608437)
  • Warn on exceptions that are likely programming errors (#2736, 36a7cf9)
  • Propagate progress correctly from unwrapped promises (#3062, d5dae25)
  • Make jQuery.when synchronous when possible (#3100, de71e97)
  • Remove undocumented progress notifications in $.when (#2710, bdf1b8f)
  • Give better stack diagnostics on exceptions (07c11c0)

Dimensions

  • Add tests for negative borders & paddings (f00dd0f)

Docs

  • Fix various spelling errors (aae4411)
  • Update support comments related to IE (693f1b5)
  • Fix an incorrect comment in the attributes module (5430c54)
  • Updated links to https where they are supported. (b0b280c)
  • Update support comments to follow the new syntax (6072d15)
  • Use https where possible (1de8346)
  • Use HTTPS URLs for jsfiddle & jsbin (63a303f)
  • Add FAQ to reduce noise in issues (dbdc4b7)
  • Add a note about loading source with AMD (#2714, e0c25ab)
  • Add note about code organization with AMD (#2750, dbc4608)
  • Reference new feature guidelines and API tenets (#2320, 6054139)

Effects

Event

  • Allow constructing a jQuery.Event without a target (#3139, 2df590e)
  • Add touch event properties, eliminates need for a plugin (#3104, f595808)
  • Add the most commonly used pointer event properties (7d21f02)
  • Remove fixHooks, propHooks; switch to ES5 getter with addProp (#3103, #1746, e61fccb)
  • Make event dispatch optimizable by JavaScript engines (9f268ca)
  • Evaluate delegate selectors at add time (#3071, 7fd36ea)
  • Cover invalid delegation selector edge cases (e8825a5)
  • Fix chaining .on() with null handlers (#2846, 17f0e26)
  • Remove pageX/pageY fill for event object (#3092, 931f45f)

Events

  • Don’t execute native stop(Immediate)Propagation from simulation (#3111, 94efb79)

Manipulation

Offset

  • Resolve strict mode ClientRect “no setter” exception (3befe59)

Selector

Serialize

  • Treat literal and function-returned null/undefined the same (#3005, 9fdbdd3)
  • Reduce size (91850ec)

Support

Tests

  • Take Safari 9.1 into account (234a2d8)
  • Limit selection to #qunit-fixture in attributes.js (ddb2c06)
  • Set Edge’s expected support for clearCloneStyle to true (28f0329)
  • Fix Deferred tests in Android 5.0’s stock Chrome browser & Yandex.Browser (5c01cb1)
  • Add additional test for jQuery.isPlainObject (728ea2f)
  • Build: update QUnit and fix incorrect test (b97c8d3)
  • Fix manipulation tests in Android 4.4 (0b0d4c6)
  • Remove side-effects of one attributes test (f9ea869)
  • Account for new offset tests (f52fa81)
  • Make iframe tests wait after checking isReady (08d73d7)
  • Refactor testIframe() to make it DRYer and more consistent (e5ffcb0)
  • Weaken sync-assumption from jQuery.when to jQuery.ready.then (f496182)
  • Test element position outside view (#2909, a2f63ff)
  • Make the regex catching Safari 9.0/9.1 more resilient (7f2ebd2)

Traversing

  • .not/.filter consistency with non-elements (#2808, 0e2f8f9)
  • Never let .closest() match positional selectors (#2796, a268f52)
  • Restore jQuery push behavior in .find (#2370, 4d3050b)

jQuery 3.0 Release Candidate…Released!

Posted on by

Welcome to the Release Candidate for jQuery 3.0! This is the same code we expect to release as the final version of jQuery 3.0 (pending any major bugs or regressions). When released, jQuery 3.0 will become the only version of jQuery. The 1.12 and 2.2 branches will continue to receive critical support patches for a while, but will not get any new features or major revisions. Note that jQuery 3.0 will not support IE6-8. If you need IE6-8 support, you can continue to use the latest 1.12 release.

Despite the 3.0 version number, we anticipate that these releases shouldn’t be too much trouble when it comes to upgrading existing code. Yes, there are a few “breaking changes” that justified the major version bump, but we’re hopeful the breakage doesn’t actually affect that many people.

To assist with upgrading, we have a brand new 3.0 Upgrade Guide. And the jQuery Migrate 3.0-rc plugin will help you to identify compatibility issues in your code. Your feedback on the changes will help us greatly, so please try it out on your existing code and plugins!

You can get the files from the jQuery CDN, or link to them directly:

https://code.jquery.com/jquery-3.0.0-rc1.js

https://code.jquery.com/jquery-3.0.0-rc1.min.js

You can also get the release candidate from npm:

npm install jquery@3.0.0-rc1

In addition, we’ve got the release candidate for jQuery Migrate 3.0. We highly recommend using this to address any issues with breaking changes in jQuery 3.0. You can get those files here:

https://code.jquery.com/jquery-migrate-3.0.0-rc1.js

https://code.jquery.com/jquery-migrate-3.0.0-rc1.min.js

npm install jquery-migrate@3.0.0-rc1

For more information about upgrading your jQuery 1.x and 2.x pages to jQuery 3.0 with the help of jQuery Migrate, see yesterday’s jQuery Migrate blog post.

 

Major changes

Below are just the highlights of the major new features, improvements, and bug fixes in these releases, you can dig into more detail on the 3.0 Upgrade Guide. A complete list of issues fixed is available on our GitHub bug tracker.

jQuery.Deferred is now Promises/A+ compatible

jQuery.Deferred objects have been updated for compatibility with Promises/A+ and ES2015 Promises, verified with the Promises/A+ Compliance Test Suite. This meant we needed some major changes to the .then() method:

  • An exception thrown in a .then() callback now becomes a rejection value. Previously, exceptions bubbled all the way up, aborting callback execution and irreversibly locking both the parent and child Deferred objects.
  • The resolution state of a Deferred created by .then() is now controlled by its callbacks—exceptions become rejection values and non-thenable returns become fulfillment values. Previously, returns from rejection handlers became rejection values.
  • Callbacks are always invoked asynchronously. Previously, they would be called immediately upon binding or resolution, whichever came last.

Consider the following, in which a parent Deferred is rejected and a child callback generates an exception:


var parent = jQuery.Deferred();
var child = parent.then( null, function() {
  return "bar";
});
var callback = function( state ) {
  return function( value ) {
    console.log( state, value );
    throw new Error( "baz" );
  };
};
var grandchildren = [
  child.then( callback( "fulfilled" ), callback( "rejected" ) ),
  child.then( callback( "fulfilled" ), callback( "rejected" ) )
];
parent.reject( "foo" );
console.log( "parent resolved" );

As of jQuery 3.0, this will log “parent resolved” before invoking any callback, each child callback will then log “fulfilled bar”, and the grandchildren will be rejected with Error “baz”. In previous versions, this would log “rejected bar” (the child Deferred having been rejected instead of fulfilled) once and then immediately terminate with uncaught Error “baz” (“parent resolved” not being logged and the grandchildren remaining unresolved).

While caught exceptions had advantages for in-browser debugging, it is far more declarative (i.e. explicit) to handle them with rejection callbacks. Keep in mind that this places the responsibility on you to always add at least one rejection callback when working with promises. Otherwise, any errors will go unnoticed.

Legacy behavior can be recovered by replacing use of .then() with the now-deprecated .pipe() method (which has an identical signature).

We’ve also built a plugin to help in debugging Promises/A+ compatible Deferreds. If you are not seeing enough information about an error on the console to determine its source, check out the jQuery Deferred Reporter Plugin.

jQuery.when has also been updated to accept any thenable object, which includes native Promise objects.

https://github.com/jquery/jquery/issues/1722
https://github.com/jquery/jquery/issues/2102

Added .catch() to Deferreds

The catch() method was added to promise objects as an alias for .then(null, fn).

https://github.com/jquery/jquery/issues/2102

Error cases don’t silently fail

Perhaps in a profound moment you’ve wondered, “What is the offset of a window?” Then you probably realized that is a crazy question – how can a window even have an offset?

In the past, jQuery has sometimes tried to make cases like this return something rather than having them throw errors. In this particular case of asking for the offset of a window, the answer up to now has been { top: 0, left: 0 } With jQuery 3.0, such cases will throw errors so that crazy requests aren’t silently ignored. Please try out this release and see if there is any code out there depending on jQuery to mask problems with invalid inputs.

https://github.com/jquery/jquery/issues/1784

Removed deprecated event aliases

.load, .unload, and .error, deprecated since jQuery 1.8, are no more. Use .on() to register listeners.

https://github.com/jquery/jquery/issues/2286

Animations now use requestAnimationFrame

On platforms that support the requestAnimationFrame API, which is pretty much everywhere but IE9 and Android<4.4, jQuery will now use that API when performing animations. This should result in animations that are smoother and use less CPU time – and save battery as well on mobile devices.

jQuery tried using requestAnimationFrame a few years back but there were serious compatibility issues with existing code so we had to back it out. We think we’ve beaten most of those issues by suspending animations while a browser tab is out of view. Still, any code that depends on animations to always run in nearly real-time is making an unrealistic assumption.

Massive speedups for some jQuery custom selectors

Thanks to some detective work by Paul Irish at Google, we identified some cases where we could skip a bunch of extra work when custom selectors like :visible are used many times in the same document. That particular case is up to 17 times faster now!

Keep in mind that even with this improvement, selectors like :visible and :hidden can be expensive because they depend on the browser to determine whether elements are actually displaying on the page. That may require, in the worst case, a complete recalculation of CSS styles and page layout! While we don’t discourage their use in most cases, we recommend testing your pages to determine if these selectors are causing performance issues.

This change actually made it into 1.12/2.2, but we wanted to reiterate it for jQuery 3.0.

https://github.com/jquery/jquery/issues/2042

As mentioned above, the Upgrade Guide is now available for anyone ready to try out this release. Aside from being helpful in upgrading, it also lists more of the notable changes.

jQuery 1.12.4 and 2.2.4 Released

Posted on by

jQuery 1.12.4 and 2.2.4 have been released! These are small releases with a couple bug fixes. We fixed a sticky issue for those using the AMD source and a “:visible” selector bug in 1.12.3.

If you need any help upgrading, check out the newest release of the jQuery Migrate plugin. Note that jQuery Migrate 1.4.1 is meant to work with these 1.x and 2.x releases, and not jQuery 3.0. jQuery 3.0 has not been released yet – though we will have an RC for you very soon – but another version of Migrate will be released for jQuery 3.0.

We do not expect this release to have any breaking changes, but if you do encounter bugs in upgrading from the previous version, please let us know.

Full changelogs

2.2.4GitHub changelog

1.12.4GitHub changelog

Download

You can include these files directly from the jQuery CDN if you like, or copy them to your own local server. The 1.x branch includes support for IE 6/7/8 and the 2.x branch does not.

https://code.jquery.com/jquery-1.12.4.js
https://code.jquery.com/jquery-1.12.4.min.js

https://code.jquery.com/jquery-2.2.4.js
https://code.jquery.com/jquery-2.2.4.min.js

These updates are already available as the current versions on npm and Bower. Information on all the ways to get jQuery is available at https://jquery.com/download/. Public CDNs receive their copies today, please give them a few days to post the files. If you’re anxious to get a quick start, use the files on our CDN until they have a chance to update.

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including Oleg Gaidarenko, Michał Gołębiowski, and the whole jQuery team.

jQuery 1.12.3 and 2.2.3 Released

Posted on by

jQuery 1.12.3 and 2.2.3 have been released! These are small releases with a couple bug fixes. There was a minor issue that made the 1.x branch inconsistent with 2.x and a recently-introduced bug in both branches that affected the .load method.

We do not expect this release to have any breaking changes, but if you do encounter bugs in upgrading from the previous version, please let us know.

Full changelogs

2.2.3GitHub changelog

1.12.3GitHub changelog

Download

You can include these files directly from the jQuery CDN if you like, or copy them to your own local server. The 1.x branch includes support for IE 6/7/8 and the 2.x branch does not.

https://code.jquery.com/jquery-1.12.3.js
https://code.jquery.com/jquery-1.12.3.min.js

https://code.jquery.com/jquery-2.2.3.js
https://code.jquery.com/jquery-2.2.3.min.js

These updates are already available as the current versions on npm and Bower. Information on all the ways to get jQuery is available at https://jquery.com/download/. Public CDNs receive their copies today, please give them a few days to post the files. If you’re anxious to get a quick start, use the files on our CDN until they have a chance to update.

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including Fredrik Blomqvist, Oleg Gaidarenko, Michał Gołębiowski, and the whole jQuery team.

jQuery 1.12.2 and 2.2.2 Released

Posted on by

We’re keeping the releases coming with two new patch releases for the 1.x and 2.x branches. These releases include a few bug fixes, which includes two edge case bugs for jQuery.isPlainObject and a bug when setting the selected property on an option element using the .prop() method in IE 11.

We do not expect this release to have any breaking changes, but if you do encounter bugs in upgrading from the previous version, please let us know.

We’ll have a release candidate of jQuery 3.0 very soon.

Full changelogs

2.2.2GitHub changelog

1.12.2GitHub changelog

Download

You can include these files directly from the jQuery CDN if you like, or copy them to your own local server. The 1.x branch includes support for IE 6/7/8 and the 2.x branch does not.

https://code.jquery.com/jquery-1.12.2.js
https://code.jquery.com/jquery-1.12.2.min.js

https://code.jquery.com/jquery-2.2.2.js
https://code.jquery.com/jquery-2.2.2.min.js

These updates are already available as the current versions on npm and Bower. Information on all the ways to get jQuery is available at https://jquery.com/download/. Public CDNs receive their copies today, please give them a few days to post the files. If you’re anxious to get a quick start, use the files on our CDN until they have a chance to update.

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including Michał Gołębiowski and Richard Gibson and the whole jQuery team.

jQuery 1.12.1 and 2.2.1 Released

Posted on by

As the jQuery team prepares for a 3.0 final release, we continue to maintain the 1.12 and 2.2 branches. These two patch releases fix a few bugs and improve stability. The most significant bug fix involved a problem with the .position() method, which affected how jQuery UI tooltips were positioned in Internet Explorer.

We do not expect this release to have any breaking changes, but if you do encounter bugs in upgrading from the previous version, please let us know.

Download

You can include these files directly from the jQuery CDN if you like, or copy them to your own local server. The 1.x branch includes support for IE 6/7/8 and the 2.x branch does not.

https://code.jquery.com/jquery-1.12.1.js
https://code.jquery.com/jquery-1.12.1.min.js

https://code.jquery.com/jquery-2.2.1.js
https://code.jquery.com/jquery-2.2.1.min.js

These updates are already available as the current versions on npm and Bower. Information on all the ways to get jQuery is available at https://jquery.com/download/. Public CDNs receive their copies today, please give them a few days to post the files. If you’re anxious to get a quick start, use the files on our CDN until they have a chance to update.

Full changelogs

2.2.1GitHub changelog

1.12.1GitHub changelog

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including Oleg Gaidarenko, Michał Gołębiowski, Zack Hall, Todor Prikumov, and Devin Wilson.

jQuery 3.0 Beta Released

Posted on by

The time has come. On this day, the 10th anniversary of jQuery, jQuery 3.0 has reached beta status. Last week, we announced the last minor releases to the 1.x and 2.x branches. Those branches will continue to receive patches for a limited time (i.e. only major regressions or bugs); jQuery 3.0 is the future. If you need IE6-8 support, you can continue to use the latest 1.12 release.

The Death of jQuery Compat

only-one

If you read the jQuery 3.0 alpha blog post, you might remember that we announced something we called “jQuery Compat”. You can forget that. On January 12, Microsoft dropped support for IE8, IE9, and IE10. We’re not going to go that far just yet, but we are dropping support for IE8. And with IE8, so goes jQuery Compat, gone before we even released a final version. There will only be one jQuery from now on!

Despite the 3.0 version number, we anticipate that these releases shouldn’t be too much trouble when it comes to upgrading existing code. Yes, there are a few “breaking changes” that justified the major version bump, but we’re hopeful the breakage doesn’t actually affect that many people. The jQuery Migrate 3.0 plugin, when released, will help you to identify compatibility issues in your code as well. Your feedback on the changes will help us greatly, so please try it out on your existing code and plugins!

You can get the files from the jQuery CDN, or link to them directly:

https://code.jquery.com/jquery-3.0.0-beta1.js

https://code.jquery.com/jquery-3.0.0-beta1.min.js

You can also get the beta version from npm:

npm install jquery@3.0.0-beta1

 

Major changes

Below are just the highlights of the major new features, improvements, and bug fixes in these releases. A complete list of changes is available on our GitHub bug tracker.

.show() and .hide() methods

In jQuery 3.0 alpha, we experimented with the idea of treating these methods like an inline-display-none-remover (.show()) and inline-display-none-adder (.hide()). This had the advantage of simplifying these methods greatly and improving performance (it required much fewer calculations). However, this proved to be problematic for our users. Removing inline display:none did not always show the element (if the element was hidden from the stylesheet, for example), and that is far too common. We realized we couldn’t provide a simple way for jQuery plugins, especially, to ensure that an element was shown.

We’ve since reverted that change, and the changes that we’ve kept for the show and hide methods should have much less of an impact on your code. In fact, even with the reversion, we’ve greatly improved performance for the case of hiding many elements.

Special case with `.data()` names

We have updated our .data() implementation to closer match the HTML5 dataset specification. All keys are now converted from kebab-case to camelCase, regardless of access method, and digits no longer participate in the conversion. For example, we will no longer differentiate between “foo-bar” and “fooBar”, but will differentiate between “foo-42” and “foo42”. These changes will mainly come into play when retrieving all data by calling .data() with no arguments, or when trying to access the data using a converted key (.data(“foo42”)) instead of the original (.data(“foo-42”)).

https://github.com/jquery/jquery/issues/1751

jQuery.Deferred is now Promises/A+ compatible

jQuery.Deferred objects have been updated for compatibility with Promises/A+ and ES2015 Promises, verified with the Promises/A+ Compliance Test Suite. This meant we need some major changes to the .then() method:

  • An exception thrown in a .then() callback now becomes a rejection value. Previously, exceptions bubbled all the way up, aborting callback execution and irreversibly locking both the parent and child Deferred objects.
  • The resolution state of a Deferred created by .then() is now controlled by its callbacks—exceptions become rejection values and non-thenable returns become fulfillment values. Previously, returns from rejection handlers became rejection values.
  • Callbacks are always invoked asynchronously. Previously, they would be called immediately upon binding or resolution, whichever came last.
  • Progress callbacks can no longer resolve Deferred objects to which they are bound.

Consider the following, in which a parent Deferred is rejected and a child callback generates an exception:


var parent = jQuery.Deferred();
var child = parent.then( null, function() {
  return "bar";
});
var callback = function( state ) {
  return function( value ) {
    console.log( state, value );
    throw new Error( "baz" );
  };
};
var grandchildren = [
  child.then( callback( "fulfilled" ), callback( "rejected" ) ),
  child.then( callback( "fulfilled" ), callback( "rejected" ) )
];
parent.reject( "foo" );
console.log( "parent resolved" );

As of jQuery 3.0, this will log “parent resolved” before invoking any callback, each child callback will then log “fulfilled bar”, and the grandchildren will be rejected with Error “baz”. In previous versions, this would log “rejected bar” (the child Deferred having been rejected instead of fulfilled) once and then immediately terminate with uncaught Error “baz” (“parent resolved” not being logged and the grandchildren remaining unresolved).

While caught exceptions had advantages for in-browser debugging, it is far more declarative (i.e. explicit) to handle them with rejection callbacks. Keep in mind that this places the responsibility on you to always add at least one rejection callback when working with promises. Otherwise, any errors will go unnoticed.

Legacy behavior can be recovered by replacing use of .then() with the now-deprecated .pipe() method (which has an identical signature).

We’ve also built a plugin to help make debugging Promises/A+ compatible Deferreds. If you figure out that there’s some phantom error getting eaten, check out the jQuery Deferred Reporter Plugin.

jQuery.when has also been updated to accept any thenable object, which includes native Promise objects.

https://github.com/jquery/jquery/issues/1722
https://github.com/jquery/jquery/issues/2102

Added .catch() to Deferreds

The catch() method was added to promise objects as an alias for .then(null, fn).

https://github.com/jquery/jquery/issues/2102

Removed special-case Deferred methods in jQuery.ajax

jqXHR object is a Promise, but also has extra methods. As users increasingly embrace the Promise pattern for asynchronous work like AJAX, the idea of having special cases with duplicate method names for the Promise returned by jQuery.ajax is an increasingly bad idea. So, these deprecated names have been removed. Instead of the special-case success, error, complete use the corresponding done, fail, always methods.

Note that this does not have any impact at all on the success, error, complete callbacks of the same name, which continue to exist and are not deprecated. This only affects the Promise methods! It also does not remove or deprecate the abort method.

https://github.com/jquery/jquery/issues/2084

Error cases don’t silently fail

Perhaps in a profound moment you’ve wondered, “What is the offset of a window?” Then you probably realized that is a crazy question – how can a window even have an offset?

In the past, jQuery has sometimes tried to make cases like this return something rather than having them throw errors. In this particular case of asking for the offset of a window, the answer up to now has been { top: 0, left: 0 } With this beta of jQuery 3.0 we’re experimenting with the idea of having such cases throw errors so that crazy requests aren’t silently ignored. Please try the beta and see if there is any code out there depending on jQuery to mask problems with invalid inputs.

https://github.com/jquery/jquery/issues/1784

.width(), .height(), .css(“width”), and .css(“height”) to return decimal values (whenever the browser does)

Previously, jQuery rounded values when retrieving width and height. Some browsers return subpixel values – such as IE and Firefox – and sometimes users need this precision when relying on these values for layout. We don’t expect this change to have a big impact on your code, but let us know if it does.

https://github.com/jquery/jquery/issues/1724

Removed deprecated event aliases

.load, .unload, and .error, deprecated since jQuery 1.8, are no more. Use .on() to register listeners.

https://github.com/jquery/jquery/issues/2286

Animations now use requestAnimationFrame

On platforms that support the requestAnimationFrame API, which is pretty much everywhere but IE9 and Android<4.4, jQuery will now use that API when performing animations. This should result in animations that are smoother and use less CPU time – and save battery as well on mobile devices.

jQuery tried using requestAnimationFrame a few years back but there were serious compatibility issues with existing code so we had to back it out. We think we’ve beaten most of those issues by suspending animations while a browser tab is out of view. Still, any code that depends on animations to always run in nearly real-time is making an unrealistic assumption.

.unwrap( selector )

Before jQuery 3.0, the .unwrap() method did not take any arguments. The selector parameter offers a way to be specific about which wrappers to remove.

https://github.com/jquery/jquery/issues/1744

jQuery.fn.domManip no longer accessible

jQuery.dir, jQuery.sibling, jQuery.buildFragment, jQuery.access, and jQuery.swap were all privatized in jQuery 1.12 and 2.2. These methods, along with jQuery.fn.domManip, were always intended for internal use only and were never documented. We are finally making them private to avoid confusion.

https://github.com/jquery/jquery/pull/2182
https://github.com/jquery/jquery/issues/2224
https://github.com/jquery/jquery/issues/2225

Massive speedups for some jQuery custom selectors

Thanks to some detective work by Paul Irish at Google, we identified some cases where we could skip a bunch of extra work when custom selectors like :visible are used many times in the same document. That particular case is up to 17 times faster now!

Keep in mind that even with this improvement, selectors like :visible and :hidden can be expensive because they depend on the browser to determine whether elements are actually displaying on the page. That may require, in the worst case, a complete recalculation of CSS styles and page layout! While we don’t discourage their use in most cases, we recommend testing your pages to determine if these selectors are causing performance issues.

This change actually made it into 1.12/2.2, but we wanted to reiterate it for jQuery 3.0.

https://github.com/jquery/jquery/issues/2042

jQuery 2.2 and 1.12 Released

Posted on by

To usher in the new year, the jQuery team has been hard at work on 2 new releases: jQuery 1.12.0 and 2.2.0! These releases include lots of bug fixes and improvements to make your cross-browser development experience better. We anticipate this to be the last releases for the 1.x and 2.x branches before we release jQuery 3.0. Since jQuery 3.0 will have some breaking changes, we will continue to support 1.12 and 2.2 after jQuery 3.0 is released, but only with patches for major regressions. As a side-note, we will have some big news related to jQuery 3.0 coming soon!

Performance Improvements

Performance of the selector engine has improved thanks to a shortcut path that immediately uses precompiled Sizzle selectors when the selector cannot be processed by the native querySelectorAll or matchesSelector methods. This results in a significant speedup in some real-world cases.

New Features

We’ve added some minor, non-breaking features that we thought might be useful in these releases. Here are some of the highlights.

SVG Class Manipulation

While jQuery is a HTML library, we agreed that class support for SVG elements could be useful. Users will now be able to call the .addClass(), .removeClass(), .toggleClass(), and .hasClass() methods on SVG. jQuery now changes the class attribute rather than the className property. This also makes the class methods usable in general XML documents. Keep in mind that many other things will not work with SVG, and we still recommend using a library dedicated to SVG if you need anything beyond class manipulation.

jQuery.post(options) and jQuery.get(options)

These ajax shortcuts have a new signature that takes a single object containing options.

jQuery.post({
  url: “/example”
});

Symbol/iterator support

We’ve added support for the Symbol type and iterators via Symbol.iterator added in ES6/ES2015. “Symbol” will be detectable with jQuery.type, and jQuery objects can be iterated with for-of where supported.

for (element of $elements) {
  console.log(element);
}

jQuery.htmlPrefilter()

A new hook has been added for filtering HTML that is passed to jQuery DOM manipulation methods like .html(), .append(), and .replaceWith(). The default prefilter translates single tags to XHTML-compatible tags. This method will allow users to bypass certain edge cases, remove scripts, and sanitize input.

jQuery.uniqueSort alias

To make it clear that jQuery.unique() also sorts, we’ve update the name. jQuery.unique will still exist, but jQuery.uniqueSort will become the documented method. This method is still only intended to sort DOM elements in document order; it is not a general sorting method.

——————————————-

We do not expect this release to have any breaking changes, but if you do encounter bugs in upgrading from the previous version, please let us know.

You can include these files directly from the jQuery CDN if you like, or copy them to your own local server. The 1.x branch includes support for IE 6/7/8 and the 2.x branch does not.

https://code.jquery.com/jquery-1.12.0.js

https://code.jquery.com/jquery-2.2.0.js

These updates are already available as the current versions on npm and Bower. Information on all the ways to get jQuery is available at https://jquery.com/download/. Public CDNs receive their copies today, please give them a few days to post the files. If you’re anxious to get a quick start, use the files on our CDN until they have a chance to update.

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including Chris Antaki, Connor Atherton, Jason Bedard, Batiste Bieler, Leonardo Braga, Bastian Buchholz, Anne-Gaelle Colom, David Corbacho, Brenard Cubacub, Aurelio De Rosa, Hamish Dickson, Ben Edelman, Stephen Edgar, Esteban, Alexander Farkas, Joelle Fleurantin, flexphperia, Corey Frang, Xue Fuqiao, Oleg Gaidarenko, Richard Gibson, Michał Gołębiowski, Scott González, goob, Christian Grete, Veaceslav Grimalschi, Mu Haibao, Dan Hart, Frederic Hemberger, Sean Henderson, Nicolas Henry, Daniel Herman, Jon Hester, Victor Homyakov, Winston Howes, Daniel Husar, Yongwoo Jeon, Essam Joubori, Taehee Kim, Richard Kraaijenhagen, Veres Lajos, Marek Lewandowski, Reed Loden, George Mauer, Richard McDaniel, Amit Merchant, Calvin Metcalf, Dave Methvin, MightyBranch, Nazar Mokrynskyi, Matthew Mueller, Julian Alexander Murillo, Martin Naumann, Daniel Nill, Alexander O’Mara, Adrian Olek, Randson Oliveira, James Pearce, Gilad Peleg, Bruno Perel, PhistucK, PJ, Senya Pugach, Aditya Raghavan, Liza Ramo, Chris Rebert, Anthony Ryan, Gabriel Schulhof, Mike Sidorov, Nick Stefan, Arthur Stolyar, Zheming Sun, Jun Sun, Timo Tijhof, Ben Toews, Thomas Tortorini, Shivaji Varma, Arthur Verschaeve, Rick Waldron, Bin Xin, Norman Xu, Gary Ye, Imran M Yousuf, and Jörn Zaefferer.

 

Full changelogs

2.2.0

Ajax

  • Remove workaround for IE6/7 (e519098)
  • remove event dependency from the ajax module (4e7f34f)
  • Fix for request aborted in ajaxSend (#1775, 598ed05)
  • use anchor tag for parsing urls (#1875, b091fdb)
  • simplify jQuery.parseXML method (5a0867d)
  • Fix cross-domain detection test for non-default port (83b038f)
  • $.post and $.get can now take an options object (#1986, 89ce0af)
  • simplify one ajax call and add explanatory comment (0ac28ed)
  • make jQuery#load “type” field explicit (4ef120d)
  • replace “jqXHR.complete” callback with “always” (97ef1f2)
  • remove use of jQuery#each second argument (a4715f4)
  • remove “onunload” event handler (a117dd0)
  • Remove jsonp callbacks through “jQuery#removeProp” method (#2323, a2ae215)
  • Account for Android 2.3 not firing window.onerror on script errors (6044fb6)
  • do not quote “throws” option – use dot notation instead (#2571, c9cf250)
  • correct indentation (cb087ce)
  • improve content-type detection (#2584, 239169b)
  • trigger error callback on native abort (#2079, 76e9a95)
  • Don’t throw exceptions on binary data response (#2498, 769446c)
  • code style fixes (8a896df)

Attr

  • Use typeof check for getAttribute method (075da30)

Attributes

  • exclusively lowercase A-Z in attribute names (22c33bf)
  • remove unnecessary element null check (55ac56a)
  • Use the option val hook in select val hook and simplify it (#1902, f6302b0)
  • fix failing test for new return value (5dc4616)
  • add SVG class manipulation (#2199, 20aaed3)
  • revert returning null for non-elements (7632b74)
  • fix tabIndex on in IE11 (#2647, c752a50)
  • revert returning null for non-existent attributes (2905961)
  • removeClass() -> attr(“class”, “”) (5db1e05)
  • Use simpler boolean check vs a function call (4bf1a09)
  • return null when attribute does not exist (#2118, aaeed53)

Authors

  • Update AUTHORS.TXT and .mailmap (03557db)

Build

  • Update QUnit to latest (1.17.1) (2d5c5d2)
  • Acknowledge Android 2.3 is not ES5-compatible (#2478, 1c59b30)
  • space between curly and paren is optional (#2399, 63a577a)
  • Moved JSHint directives to .jshintrc file (15a609f)
  • update AUTHORS.txt (8f13997)
  • Add a comment explaining why the es3 option is needed (669cb16)
  • Upgrade to commitplease 2.0.0 (5bc1ddc)
  • Refactor Node smoke tests (9c8a3ec)
  • update version to 3.0.0-pre (7a607c5)
  • Fix various typos (dc4b914)
  • Update jscs and lint files (#2056, 10fdad7)
  • correct jscs paths (99975c4)
  • Remove empty define({}) from build output (#1768, 2c1b556)
  • correct style tests files which could be automatically corrected (e35bdc1)
  • Update commitplease dev dependency (39b7606)
  • Update grunt-contrib-jshint (1556c46)
  • remove bower.json lint target (285cfbf)
  • fix tests in AMD mode (6051609)
  • Update grunt-contrib-uglify because of a security issue in uglify (835e921)
  • Update the license attribute (#2331, 8e92e1e)
  • update requirejs dependency to 2.1.17 (#2290, a644101)
  • bower.json: remove moot `version` field (61e21a4)
  • put back “lint” command to the “dev” list (5adf04a)
  • Upgrade to grunt-bowercopy 1.0.0 (323e82c)
  • account for version labels in Sizzle versions (#1939, 78ac753)
  • update node dependencies (9101704)
  • Sizzle version labels must start with a dash (d6c97ab)
  • Don’t assume the browser environment; smoke test on Node w/ jsdom (#1950, 76df9e4)
  • Remove dates from copyright notice (66e1b6b)
  • Specify valid components for commit messages (0c9d018)
  • Fix an email address of a contributor (ab30934)
  • Remove unused Sizzle test files (8d11310)
  • Move all external libraries to external directory (c5d9d88)
  • Don’t install jsdom 3 on Node.js 0.10 & 0.12 by default (#2519, dbb2daa)
  • use different versions of jsdom for Node and iojs testing (#2266, 5c3101f)
  • Rearrange grunt/npm tasks into a build/dist/test pattern (bb928bd)
  • Remove npm from dependencies (b92acf7)
  • Sanctify the component name status of Wrap (a4133ff)
  • Drop io.js testing, test on latest Node.js (250a199)
  • Use double quotes in .travis.yml (06320c8)
  • Test on Node 5 (cbe5b2b)
  • Speed up the Travis build (31f4f8e)
  • Remove a double empty line at the end of .travis.yml (cea94a8)
  • ignore test dependencies for npm install (35f8e15)
  • update Sizzle to 1.11.1 and include license (c0b23e2)
  • update grunt-bowercopy (712e78c)
  • Add “deprecated” to the Testswarm module list (1144e75)
  • Update license (4f776e5)
  • update Sizzle (#2042, #1969, 3a0dd5a)
  • Move test to appropriate module (fbdbb6f)
  • update Sizzle to 2.0.0 (bcca4f0)
  • add mailmap entry (3ec73ef)
  • drop bower; use npm for front-end deps (#15186, e1949f4)
  • update front-end dependencies (8356948)
  • fix broken assertions caused by QUnit update (8b6aeae)
  • Change the 2.2-stable version to 2.2.0-pre (c56e8b6)
  • Update native-promise-only (again) (f5aa89a)
  • update Sizzle to 2.2.1 (#2390, 44f8239)
  • Update native-promise-only (0065e1f)
  • remove deprecated JSHint options (34da7d5)
  • save sinon update for later (#2160, 98c25b7)
  • update node dependencies barring jscs (8e3a0ce)
  • update grunt-jscs-checker and pass with the new rules (c869a1e)
  • update source map options for the new grunt jshint (269a27c)
  • Fixed issue with base path that contain ‘var’ (#2450, 0c34e68)

Callbacks

CONTRIBUTING

  • Condense info and add directions to other resources (#1824, bfd5dab)
  • Close parenthesis (609adf6)

Core

  • Align branches: remove an unused variable, add comments (f6de5a9)
  • use interactive to evaluate dom ready, barring IE9-10 (#2100, dabd5ba)
  • Test all factory use cases from intro.js (#2181, ab40725)
  • add workaround for iOS JIT error in isArrayLike (#2145, 1541664)
  • CSS:Event: simplification of native method signatures (85577a3)
  • allow init to accept an alternate rootjQuery for migrate’s sake (#2101, 7a6931d)
  • remove isArraylike check for nodes (#2238, 436f0ae)
  • Standardize indexOf comparisons (53aa87f)
  • Support Symbol wrapper objects in jQuery.type (8a73434)
  • make isNumeric test work on Symbol (0703fd5)
  • CSS: disable 2 tests for Opera 12 (13d2de7)
  • Remove unnecessary parameter to jQuery#constructor (98cee73)
  • Update tested jsdom, drop obsolete workarounds (#2153, 06f6cd1)
  • change jQuery.each and jQuery#each signatures (#2090, 2380028)
  • re-introduce createHTMLDocument in parseHTML; Safari 8 left out (cfe468f)
  • revert addition of createHTMLDocument. Thanks, Safari 8. (b779831)
  • Consistently use local reference to access() (2fb719e)
  • pass empty string to createHTMLDocument to appease IE (31c7d7f)
  • remove unnecessary support test for createHTMLDocument (5923282)
  • use document.implemenation.createHTMLDocument in jQuery.parseHTML (58c2460)
  • Simplify and speed up .each (eeda11c)
  • simplify “each” stylesheet iteration test (fcb6c4d)
  • add unit test for isPlainObject(Symbol) (#2645, 9090d98)
  • Follow the AMD specification for define (892625b)
  • Make jQuery objects iterable (#1693, bb026fc)
  • Use window.setTimeout & friends instead of global equivalents (#2177, 219c749)
  • Don’t expose jQuery.access (#2513, 9adfad1)
  • Switch from modules to just window.setTimeout etc. (842958e)
  • Drop strundefined variable (29838b6)
  • organize prop & attr code to be similar (5153b53)
  • Adjust comments & tests after dropping Safari 6 support (93bee47)
  • .each/.map should accept an undefined/null value (#2267, bf48c21)
  • Add a support comment for Safari 8 (d242753)

Css

  • Fix the “sanity check” test (995f707)
  • Remove non-functional unit test for negative margin (4ab7431)

CSS

  • fix :visible/:hidden selectors for inline element w/ content (#2227, 79bcb29)
  • save 20 bytes in css/support (45ec73f)
  • Don’t name the anonymous swap function (0019a46)
  • Correct misrepresentation of “auto” horizontal margins as 0 (#2237, 487d5ca)
  • Use pre-defined displays for html and body (a772418)
  • Support relative adjustment in any applicable unit (#1711, 9b03f6d)
  • use isFinite in place of redundant isNumeric (3689963)
  • Clean up memory leak in reliableMarginRight (#1795, 7d15b4d)
  • Correct typo in the comment (7e09619)
  • elements are hidden when either offsetWidth or offsetHeight is zero (#10406, #13132, 10399dd)
  • Add animation-iteration-count to cssNumber, fix tests (#2792, b9a6958)
  • Don’t cache unrecognized CSS property names (#2015, d471842)
  • Collapse a double if statement into one (7855a1a)
  • Add unit tests for negative margins and positioning (1b932bb)
  • Work around an IE11 fullscreen dimensions bug (#1764, 90d828b)
  • Restore the hack to get pixels for .css(‘width’) etc. (3747cc6)
  • make the getStyles function more readable (3a0d582)
  • Fix the pixelMarginRight support test in Android 2.3 (cdfc2d0)
  • Don’t expose jQuery.swap (#2058, bb4d888)
  • simplify “defaultDisplay” module (c62486f)
  • Improve a comment explaining IE11 fullscreen bug (8e4aac8)
  • Add an integration test for issue gh-1764 (8887106)
  • Removed redundant “to the number” in comment (895ea68)
  • Remove use of getDefaultComputedStyle (#15227, 274feb5)

Data

  • move element cache to element[expando] (#1734, d702b76)
  • updates to element[expando] cache (222ac3a)
  • shave off a couple of bytes (6f65f5f)
  • restore explicit data removal of private data in cleanData. (#2127, 332fd94)
  • remove user data in cleanData (#2503, 5fe76c6)
  • avoid Object.defineProperties for nodes (#1728, 95fb798)
  • speed up $.fn.data() for camel-cased key (#1941, 72c4a06)
  • find hyphenated data with camelCased key (#2779, c1511c6)
  • avoid non-alphanumeric chars in expando properties (0cdec79)
  • Drop the tests relying on applets (#1938, 95c0a10)
  • Combine register and cache methods (b5f7c9e)
  • avoid using delete on DOM nodes (0e98243)
  • Don’t expose jQuery.acceptData (#2555, 2242719)
  • Use a PDF object instead of a Java applet for acceptData testing (#1938, 087d280)
  • do not create data cache when fetching single property (f5bf9bc)
  • remove the expando when there’s no more data (#1760, 56bb677)
  • remove some unused code (764dc94)

Deferred

  • Fix $.when with resolved deferred and progress callbacks (#1894, ab20d9d)
  • Always handle progress callbacks before done/fail (#2013, #2010, 002240a)

Deprecated

  • fix amd mode for the deprecated module (e271f66)

Dimensions

Docs

  • Fix README uppercase (b50e0f2)
  • remove redundant instruction from the readme (#2359, 3c92770)
  • correct grunt command in README.md (#1850, 9d6beac)
  • 1.x-master branch -> compat branch; 2.x branch -> master branch (758fd6c)
  • Clarify custom build instructions (a3779bc)
  • Add info about Sizzle not being excludable on the compat branch (#2184, 062b526)
  • Fix various spelling mistakes (360a478)
  • “npm run build” was missing from the contributing guides (735dea3)

Effects

  • set default easing using jQuery.easing._default (#2219, 5f2ea40)
  • Remove tests for jQuery.Animation & jQuery.Tween (a5864ae)
  • Improve raf logic (708764f)
  • Finish should call progress (#2283, 3dd3d13)
  • manually revert two `requestAnimationFrame` commits (0a98623)
  • add tests for jQuery.easing._default in Animation and Tween (6d7ef56)
  • Add tests for jQuery.Tween (cdaed15)
  • Adding unit tests for jQuery.Animation (b3b2d6c)
  • Reintroduce use of requestAnimationFrame (#15147, 72119e0)

Event

  • HTML5 drop events inherit from MouseEvent (#2009, d7e5fce)
  • Ensure delegation doesn’t error on comment nodes (#2055, 493b0fd)
  • remove preDispatch hook & simplify “simulate” signature (3655c4e)
  • Copy detail property to jQuery.Event on native events (#1867, d9ed166)
  • Fully clean up events in unit test (4467ed6)
  • Update support comments for mouseenter/mouseleave implementation (2792845)
  • Add a note about a mouseenter bug in Chrome (a5e1c9b)
  • Empty namespaces should be uneventfully ignored (8653068)
  • remove outdated originalEvent hack (6df669f)
  • Remove fake originalEvent from jQuery.Event.simulate (#2300, 7475d5d)
  • Add basic unit tests for event aliases (#2302, e05c63e)
  • Fix delegated radio events when arrow keys are used (#2343, c82a668)
  • Make event aliases optional in unit tests (2cb8eba)
  • provide verbose comment for focus(in | out) & rename support prop (c074006)
  • Move .bind() and .delegate() to deprecated (#2288, ee0854f)
  • Separate trigger/simulate into its own module (#1864, c9935b6)
  • Move VML test out of event alias test (67fa2ea)
  • Remove an internal argument to the on method (04a2969)
  • fix incorrect window bug with scrollTop/Left in iframes (#1945, d21edb5)
  • fix incorrect test (d923100)
  • Restore the `constructor` property on jQuery.Event prototype (#15090, b807aed)
  • Only check elements for delegation matches (9d820fb)
  • remove redundant guards for the event methods (#2047, a873558)
  • add support comment (9db9316)
  • correct support comment (361a0d5)
  • Normalize mouse event properties in drag events (#1925, 97cf528)

Manipulation

Misc

  • Mac OS is now OS X, thanks @xfq (d30c482)
  • Fix the tests, revert some unneeded/broken reverts (1ad9915)
  • Need for speed removed by 9ad6e7e (ff928f5)
  • Update all references to bugs.jquery.com (#1681, 3e89a53)
  • Remove leftover -moz-box-sizing in tests (e81b258)
  • Adjust comments & docs to dropping IE<8 in jQuery Compat (c309b95)

Offset

  • offsetLeft/Top on empty set returns undefined (#2319, 2937019)
  • allow offset setter to throw for disconnected elements (#2114, 0d11c11)
  • allow small differences in offset.top (#2590, 9f9e204)
  • don’t run scrollTop/scrollLeft iframe test in Android 2.3 & 4.0 (#1981, 0c46643)
  • add tests for hidden elements + scroll (b041242)
  • return before getBoundingClientRect to avoid error in IE8-11 (0e4477c)
  • Round offset value for the sake of floating errors (#2147, 62ae2d0)
  • return zeros for disconnected/hidden elements (#2310, 40dcc76)
  • Simplified a conditional (4287442)
  • account for scroll when calculating position (#1708, 2d71594)
  • don’t run scrollTop/scrollLeft iframe test in mobile Safari (4ab8603)
  • simplify jQuery#offsetParent method (74ae544)
  • do not run tests which break without back-incompat change (9d1d4c2)

Readme

  • Fix minor style issues. Thanks @MightyBranch! (edfc94d)
  • Fix punctuation in tile (df62159)

README

  • Improve build instructions (2e9c1ea)
  • Update the description of the deprecated module (1d75273)
  • various text fixes (31b63fc)
  • Add selector-native.js link. Thanks @randsonjs! (cfe2eae)
  • update the Homebrew site address (b410b15)

Release

  • bower.json is actually generated from scratch (61224f5)
  • update AUTHORS.txt (ae3229c)
  • Distribute files to distribution repo (#1869, #1673, #2045, 26eca14)
  • remove antiquated release-notes.js (7bb39f3)
  • properly set the dist remote when it’s a real release (c44dd77)
  • remove revert artefacts (3655260)
  • update AUTHORS.txt (e905dcd)
  • fix revert artefacts (e2af987)
  • allow local and github dists (47c21ef)
  • ensure files are copied to dist (b4e139c)
  • Remove copying of jquery-latest files (c34ed46)
  • remove revert artefacts (c69673f)
  • push dist to same remote as project (1ba45fc)
  • fix revert artefacts (ae88b39)
  • remove sourcemap comment from all copies of minified file (#1707, a76c781)
  • fix CDN archive creation (#1940, e0673df)
  • dist can be run during a test (aae998b)

Selector

  • pass jQuery unit tests with selector-native (#1742, #2048, 8804644)
  • Remove “#” exception for identifier tokens (86e62d8)
  • Define jQuery.uniqueSort in selector-native too (#2466, bf591fb)
  • add test for jQuery.unique() alias (add85af)
  • add jQuery.uniqueSort; deprecate jQuery.unique (#2228, e1090c3)

Serialize

  • Handle arrays with null values (3d7ce0a)
  • Fix object detection (14c0fe4)

Sizzle

Support

  • Re-organize browser order, add Safari 8 (43faf6d)
  • Correct iOS 8 support test results, re-arrange entries (ce308e2)

Tests

  • Post-Summit cleanup (f931786)
  • Use standard external domain name (5b554cf)
  • Make basic tests work in IE 8 (5914b10)
  • Don’t load non-basic tests when basic module is selected (855b0c8)
  • Add simple tests for Android 2.3 (#2505, 2c7e9c9)
  • Lower the checks rounding error (a44cfa0)
  • Use QUnit URL parameter parsing (f23a64d)
  • more style corrections (c161eec)
  • Disable/relax a few tests failing in Android 2.3 (#1785, 1a9c9b0)
  • further improvements QUnit 2.0 migration (c8d15a2)
  • fix tests in accordance with new :visible behavior (16713fb)
  • hotfix for c1511c673148208ab17cafa0faf37bce3b4ae392 (3f839af)
  • lower the PHP sleep time in unreleasedXHR.html (02e1008)
  • Fix support tests results for Android 2.3 (4fea389)
  • Add Safari 9 support tests results (e99a3ac)
  • Add dummy modules when running basic tests (f9af896)
  • Blacklist the iframe scrollTop test in Opera 12.1x (283a194)
  • do not define two modules with the same name (#2437, 7aa46e0)
  • partially use new qunit interface (#2540, b930d14)
  • Correct a typo in the regex matching Safari 8 (c17543f)
  • Change quotes according to style guidelines (c577928)
  • fix lint in restored test (636a2bd)
  • Remove a trailing comma for compatibility with the compat branch (dc8ba6a)
  • make editorconfig match css style (1da1448)
  • make top of the HTML suite compliant with style guide (8356281)
  • Accept Android 2.3 doesn’t fire window.onerror for remote scripts (2732531)
  • Add Microsoft Edge results (from Windows 10 build 10130) (8e111df)
  • Keep test iframes around for assertions (0fb84fa)
  • Account for array-like objects in jQuery.grep (67b76f5)
  • fix code style issues (625bd30)
  • Fix support tests results (f6dd767)
  • Account for Edge in originalEvent UA-sniffs (#2357, 64fd7ef)
  • Remove Safari 7.0 & iOS 6 support tests results (47e2aa6)
  • Remove Edge version from the user agent (5a1217e)
  • Tilt at a few style guide windmills (906caeb)
  • Accommodate page changes from the QUnit HTML reporter (3c13f4c)
  • Remove test/data/ua.txt (#2398, e831856)
  • Minor updates for QUnit 1.16 compatibility (26276a3)
  • Update QUnit (6748ba3)
  • Add iOS 9 support tests results (1c2b536)
  • Fix CSS relative adjustment test for round-down browsers (48be675)
  • Increase QUnit timeout (ff18d8e)
  • Expand CSS relative adjustment tolerance for IE (e22ef5d)
  • don’t use deprecated argument in test declaration (aabe94e)
  • Provide equal() arguments in correct order (actual, expected) (d3d8d97)
  • Docs: Fix various typos (03eaadb)
  • add the current version of node and iojs to the travis config (bd9a138)
  • Make regexes for iOS devices more rigid (015d16c)
  • Add .extend test for defined accessor properties (9748e43)
  • Fix Safari 5.1 support tests results (e904249)
  • Really fix tests in IE 8 this time (1b566d3)

Traversing

  • Don’t expose jQuery.dir & jQuery.sibling (#2512, f9ef427)

1.12.0

Ajax

  • Add support comment and fix code style issue (e38a94a)
  • remove event dependency from the ajax module (c580a52)
  • Fix for request aborted in ajaxSend (#1775, 73c1cea)
  • Fix cross-domain detection test for non-default port (b635ee2)
  • $.post and $.get can now take an options object (#1986, 26150f0)
  • Run the PATCH test only in IE8 on TestSwarm (#1994, 2524da0)
  • make jQuery#load “type” field explicit (1d3d2b1)
  • replace “jqXHR.complete” callback with “always” (fd80f59)
  • move explanatory comment to appropriate place (04fc801)
  • remove use of jQuery#each second argument (0877733)
  • Use the native XHR for all non-local requests in IE9+ (#1684, 61f812b)
  • Rename Spartan to Edge in a comment (8d88cd5)
  • Fix the XHR fallback logic for IE8 (bd699cb)
  • Remove jsonp callbacks through “jQuery#removeProp” method (#2323, 3d850ed)
  • Account for Android 2.3 not firing window.onerror on script errors (b3eb2a1)
  • do not quote “throws” option – use dot notation instead (#2571, c530661)
  • Mitigate possible XSS vulnerability (#2432, f60729f)
  • correct indentation (2a83417)
  • improve content-type detection (#2584, 3ced5ab)
  • don’t expect cross-origin tests run in envs which not support it (905ab09)
  • Catch synchronous readystatechange events (#2673, 0a6e1c4)
  • Don’t let onreadystatechange preempt exceptions from xhr.send (b5c6fc7)

Attributes

  • fix IE6-7 classes (9e2f55f)
  • don’t test SVG CSS-class manipulation in IE8 (57fb2dc)
  • remove unnecessary element null check (0de798d)
  • fix IE8 issues (f2bcf87)
  • revert returning null for non-existant attributes (7bce5b0)
  • remove flakey test for selected attribute (689270e)
  • fix tabIndex on in IE11 (#2647, cf4092e)
  • revert returning null for non-elements (a403655)
  • add SVG class manipulation (#2199, b5b0d72)
  • removeClass() -> attr(“class”, “”) (f5328b6)
  • Use simpler boolean check vs a function call (c003cd6)
  • fix failing test for new return value (17bd6e9)
  • return null when attribute does not exist (#2118, afca031)
  • Simplify the option val hook; backport a test from master (#1902, aec41a5)
  • fix toggleClass(boolean) in ie6/7 (41c83f5)

Authors

  • Update AUTHORS.txt and .mailmap (d39fef8)

Build

  • update grunt-jscs-checker and pass with the new rules (91e06e9)
  • update source map options for the new grunt jshint (181b451)
  • update requirejs dependency to 2.1.17 (#2290, a9296df)
  • denote that sizzle cannot be removed on this branch (#14775, 764f364)
  • Rearrange grunt/npm tasks into a build/dist/test pattern (0771973)
  • Update the license attribute (#2331, 8bf81d7)
  • append “+compat” to tag version and jQuery.fn.jquery (#2269, d18b645)
  • remove bower.json lint target (24a6bb9)
  • Update grunt-contrib-jshint (a022da7)
  • Remove npm from dependencies (a16b77f)
  • Temprary disable jscs checks (0e3fa47)
  • code style fixes (8c507df)
  • Upgrade to commitplease 2.0.0 (630a5a8)
  • remove needless file and re-enable jscs (813b7e4)
  • update Sizzle (#2042, #1969, 345c95a)
  • 1.x-master -> compat (2912ddd)
  • Put “jQuery Compat” in banners in built files (8cd6875)
  • Update license (9dfb9af)
  • Point to files from the compat branch, not master (b7663ea)
  • Fix various typos (3f9fda8)
  • remove node .10 from travis (498fd24)
  • Update native-promise-only (again) (f9f4f9d)
  • Test on Node 5 (06840d8)
  • code style fixes after all those reverts (14eba98)
  • ignore test dependencies for npm install (ae7a15b)
  • Update commitplease dev dependency (a96ed7e)
  • update AUTHORS.txt (799332f)
  • Upgrade to grunt-bowercopy 1.0.0 (5150442)
  • add mailmap entry (1682d36)
  • just tack on +compat to versions that may include labels (8565f54)
  • Remove unused Sizzle test files (62f7f7b)
  • Move all external libraries to external directory (72e6192)
  • update Sizzle to 1.11.1 and include license (1c31384)
  • update grunt-bowercopy (b3edc61)
  • Add “timers_ie.js” file back to the repo (31e6697)
  • Correct indentation issue (d0f27a7)
  • Add a comment explaining why the es3 option is needed (b988c0e)
  • Remove empty define({}) from build output (#1768, 2138f15)
  • bower.json: remove moot `version` field (3699ef4)
  • update Sizzle to 2.2.1 (#2390, 20cd343)
  • drop bower; use npm for front-end deps (#15186, 79c0732)
  • correct jscs paths (fa8a5a9)
  • Update jscs and lint files (#2056, 20ddbe4)
  • Add “deprecated” to the Testswarm module list (b94af72)
  • remove deprecated JSHint options (9edd95f)
  • fix broken assertions caused by QUnit update (98c77c1)
  • space between curly and paren is optional (#2399, cbb0be6)
  • update front-end dependencies (4089c7d)
  • fix tests in AMD mode (57652ee)
  • Update grunt-contrib-uglify because of a security issue in uglify (2da0cca)
  • Update QUnit to latest (1.17.1) (db31206)
  • another portion of code style fixes (f913a01)
  • update node dependencies barring jscs (511eb15)
  • account for version labels in Sizzle versions (#1939, ac70dd0)
  • update node dependencies (dda65fb)
  • Fixed issue with base path that contain ‘var’ (#2450, 4e3f971)
  • Sizzle version labels must start with a dash (6bc0e50)
  • Fix an email address of a contributor (648280a)
  • Speed up the Travis build (ba352e8)
  • Don’t install jsdom 3 on Node.js 0.10 & 0.12 by default (#2519, 5f1c7fc)
  • Sanctify the component name status of Wrap (abfb10c)
  • Remove dates from copyright notice (a0bf5bf)
  • Specify valid components for commit messages (6f0db53)
  • Remove a double empty line at the end of .travis.yml (fc87a5c)
  • Use double quotes in .travis.yml (ca0dd7a)
  • Drop io.js testing, test on latest Node.js (d29c394)
  • Move test to appropriate module (9953ae4)
  • Update native-promise-only (7b11131)

Callbacks

CONTRIBUTING

  • Condense info and add directions to other resources (#1824, 404d2aa)

Core

  • Consistently use local reference to access() (eeab75d)
  • add support to tag-hyphenated elements (f19595c)
  • Remove unnecessary parameter to jQuery#constructor (dc76dca)
  • Support Symbol wrapper objects in jQuery.type (c7cf286)
  • simplify “each” stylesheet iteration test (889bb1e)
  • add unit test for isPlainObject(Symbol) (#2645, d3a2fdc)
  • introduce createHTMLDocument in parseHTML; Safari 8/IE8 left out (828a718)
  • change jQuery.each and jQuery#each signatures (#2090, 7cd9a36)
  • remove isArraylike check for nodes (#2238, d693391)
  • Simplify and speed up .each (4cc4e54)
  • Support non-browser environments (#2133, #2501, 04ec688)
  • CSS: Attach test nodes to documentElement, not body (#2502, 9b04201)
  • make isNumeric test work on Symbol (d846c25)
  • Don’t expose jQuery.access (#2513, 12230d3)
  • Adjust comments & tests after dropping Safari 6 support (5fce498)
  • .each/.map should accept an undefined/null value (#2267, 15f4804)
  • Add a support comment for Safari 8 (9c373c3)
  • Make jQuery objects iterable (#1693, 2fa3bac)
  • Align code in intro.js with master (fe2a584)
  • Update tested jsdom, drop obsolete workarounds (#2153, 19c0377)
  • Standardize indexOf comparisons (6ae222a)
  • Drop strundefined variable (835e8c4)
  • organize prop & attr code to be similar (d0388e9)
  • Change support.ownLast to support.ownFirst (#2406, 453738a)
  • Follow the AMD specification for define (acf2d0c)
  • add workaround for iOS JIT error in isArrayLike (#2145, 1e7a2f3)
  • CSS:Event: simplification of native method signatures (49bce47)
  • allow init to accept an alternate rootjQuery for migrate’s sake (#2101, c916aef)

Css

  • Fix the “sanity check” test (da84cb6)
  • Remove non-functional unit test for negative margin (1ece10f)

CSS

  • Add a support test for the hack for .css(‘marginRight’) etc. (25bc680)
  • fix :visible/:hidden selectors for inline element w/ content (#2227, dd816db)
  • fix AMD mode for the new showHide module (0b6846c)
  • fix visible/hidden for IE6/7 (ecf52b9)
  • use isFinite in place of redundant isNumeric (24ab836)
  • Protect against getBoundingClientRect exceptions (c40b12a)
  • elements are hidden when either offsetWidth or offsetHeight is zero (#10406, #13132, 7b9b98d)
  • Add an integration test for issue gh-1764 (7ee0fea)
  • Don’t name the anonymous swap function (e847574)
  • Fix the pixelMarginRight support test in IE8 (4a67512)
  • Improve a comment explaining IE11 fullscreen bug (5895340)
  • Removed redundant “to the number” in comment (b59b819)
  • Fix get upper case alpha opacity in IE8 (#1705, c5e8e12)
  • Support relative adjustment in any applicable unit (#1711, 6fb2cef)
  • make the getStyles function more readable (bf282ea)
  • Add animation-iteration-count to cssNumber, fix tests (#2792, 01fb17b)
  • Work around an IE11 fullscreen dimensions bug (#1764, 6df1bf9)
  • remove revert artefact (fc6ac9d)
  • Don’t expose jQuery.swap (#2058, 02a9d9f)
  • Correct typo in the comment (787ffbf)
  • Remove use of getDefaultComputedStyle (44c9c4f)
  • Don’t cache unrecognized CSS property names (#2015, 42ea746)
  • Correct misrepresentation of “auto” horizontal margins as 0 (#2237, 214e163)
  • fix reliableHiddenOffsets support test for IE6-7 (77f9b1e)
  • fix dependency order for amd (e185aa3)
  • Use pre-defined displays for html and body (b05b6a2)
  • Add unit tests for negative margins and positioning (ae30fb6)
  • Clean up memory leak in reliableMarginRight (#1795, fa70df6)

Data

  • Use a PDF object instead of a Java applet for acceptData testing (#1938, 4e3c48f)
  • Don’t expose jQuery.acceptData (#2555, bec2ba2)
  • use removeAttribute in cleanData to bypass Chrome bug (#1664, 9d1d90e)
  • backport cleanData tests from gh-2480 (624d6a8)
  • test that delete is not used on DOM nodes (5a7674d)

Deferred

  • pass lint in new catch tests (203979d)
  • Always handle progress callbacks before done/fail (#2013, #2010, 35295f1)
  • Fix $.when with resolved deferred and progress callbacks (efb98f8)

Deprecated

  • fix amd mode for the deprecated module (bd11778)

Dimensions

  • allow modification of coordinates argument (1eedf0e)

Docs

  • Rename 1.x to compat (8992ac8)
  • remove redundant instruction from the readme (#2359, e6a492d)
  • correct grunt command in README.md (38ac3c4)
  • Clarify custom build instructions (8e738f0)
  • Fix various spelling mistakes (6af92ca)
  • 1.x-master branch -> compat branch; 2.x branch -> master branch (b8a0843)
  • “npm run build” was missing from the contributing guides (5da5035)

Effects

  • Finish should call progress (#2283, f71e32d)
  • Add tests for jQuery.Tween (6b10f9d)
  • Remove tests for jQuery.Animation & jQuery.Tween (bc53033)
  • add tests for jQuery.easing._default in Animation and Tween (b9b5c23)
  • set default easing using jQuery.easing._default (#2219, b7f9e62)
  • Remove needless operations in tests (13040b6)
  • add back support.shrinkWrapBlocks() for ie6 (1f85ded)
  • fix failing tests in IE8 (fe6afa8)
  • Fix tests (29561bc)
  • Adding unit tests for jQuery.Animation (0ff8057)

Event

  • Use form prop so that a propHook can be used (#2332, ead83b9)
  • improve originalEvent hack (37c3d08)
  • Remove an internal argument to the on method (473d2db)
  • Empty namespaces should be uneventfully ignored (51564bb)
  • fix incorrect test (e73a67f)
  • add test for window scrollTop/Left logic in iframes (2c14b00)
  • Move .bind() and .delegate() to deprecated (#2288, 7e78c2e)
  • Add reference to data module (2866da9)
  • Normalize mouse event properties in drag events (#1925, 5b0b1b7)
  • HTML5 drop events inherit from MouseEvent (#2009, a05de40)
  • Add a note about a mouseenter bug in Chrome (f3e3a20)
  • provide verbose info for focus(in | out) & rename support props (401a351)
  • Restore the `constructor` property on jQuery.Event prototype (#15090, d4a998f)
  • correct support comment (fae2daa)
  • Reduce differences from master (3923bb8)
  • remove preDispatch hook & simplify “simulate” signature (05e54ce)
  • add support comment (0fc5beb)
  • Reduce differences from master (e4c5f87)
  • Update support comments for mouseenter/mouseleave implementation (d176001)
  • Copy detail property to jQuery.Event on native events (#1867, a90ff8c)
  • correct an unfinished comment (ac23f91)
  • Fix delegated radio events when arrow keys are used (#2343, 657c2f8)
  • Fully clean up events in unit test (ef93f95)

Manipulation

  • re-expose domManip until 3.0 (#2225, 95de105)
  • increase delay of data-URI test (30ace26)
  • support data-URI scripts insertion (bc1902d)
  • don’t test data-URI with script element in IE8 (503e545)
  • Detect sneaky no-content replaceWith input (#2204, 4cafb58)
  • privatize internal domManip() function (#2225, 590eff6)
  • Plug an IE8 memory leak in noCloneEvent feature detect (#1840, faf295a)
  • Make an HTML interception point (#1747, fb25bac)
  • privatize buildFragment() function (#2224, 63c1414)
  • improve test for data-URI (a467f86)
  • Update html5shiv elements (#15241, a953389)
  • correct wrapMap assign (a5be90f)
  • Remove an internal argument to the remove method (#2301, b819be3)
  • Don’t provide the parser with sloppy table markup (#2493, 81b6e46)
  • Switch rnoInnerhtml to a version more performant in IE (#2563, 29266e0)
  • add support to tag-hyphenated elements (5d522f5)
  • blacklist IE8 from running tests for tag-hyphenated elems (87bb713)

Misc

  • Mac OS is now OS X, thanks @xfq (598946d)
  • Need for speed removed by 9ad6e7e (519d99a)
  • Update all references to bugs.jquery.com (#1681, 49c720e)

Offset

  • return before getBoundingClientRect to avoid error in IE8-11 (25e8620)
  • fix iframe scrollTop/Left test for IE8 (d632699)
  • fix iframe scrollTop/Left test for IE8 and iPhone (62a333e)
  • Round offset value for the sake of floating errors (#2147, cd63e9c)
  • don’t run scrollTop/scrollLeft iframe test in Android 2.3 & 4.0 (#1981, f2ea60c)
  • return zeros for disconnected/hidden elements (#2310, 63f19a9)
  • account for scroll when calculating position (#1708, 0654711)
  • do not run tests which break without back-incompat change (9f2dcb9)
  • getBounding doesn’t return width/height in IE8. Fixes test. (3b1de11)
  • no need to check for ownerDocument (523de77)
  • revert to jQuery.contains for IE8’s sake (compat only) (6df3990)
  • allow small differences in offset.top (#2590, d047073)
  • add tests for hidden elements + scroll (a0a5c0b)

Readme

  • Fix punctuation in tile (a751bfe)

README

  • various text fixes (3d77c2e)
  • update the Homebrew site address (d588c85)
  • Improve build instructions (07afc28)
  • Update the description of the deprecated module (2a3018c)

Release

  • ensure files are copied to dist (f5029f5)
  • fix CDN archive creation (#1940, 7352216)
  • remove sourcemap comment from all copies of minified file (#1707, f71d7f5)
  • push dist to same remote as project (5e5489c)
  • Distribute files to distribution repo (#1869, #1673, #2045, fc76a97)
  • update AUTHORS.txt (ce4822c)
  • compat -> 1.x. Remove compat-specific release semantics (25d0afa)
  • update AUTHORS.txt (8b0618c)
  • update AUTHORS.txt again (0398d90)
  • properly set the dist remote when it’s a real release (9162122)
  • Remove copying of jquery-latest files (16fcc5e)
  • dist can be run during a test (dcd2c8f)
  • allow local and github dists (3a4a95c)

Selector

  • add test for jQuery.unique() alias (17ce9ed)
  • Remove “#” exception for identifier tokens (41f522a)
  • add jQuery.uniqueSort; deprecate jQuery.unique (#2228, d9d930f)

Serialize

  • Handle arrays with null values (f0b86ec)
  • Fix object detection (a993056)

Sizzle

Support

  • Correct iOS 8 support test results, re-arrange entries (a4e31a8)
  • Re-organize browser order, add Safari 8 (7e70867)

Test

  • Switch leftover andSelf to addBack (2ea57c1)

Tests

  • Expand CSS relative adjustment tolerance for IE (9d255b3)
  • Post-Summit cleanup (a93d1d7)
  • Add iOS 9 support tests results (dec9ab9)
  • Remove Safari 7.0 & iOS 6 support tests results (602c34d)
  • Make regexes for iOS devices more rigid (8339185)
  • Do not define two modules with the same name (#2437, 85aed35)
  • lower the PHP sleep time in unreleasedXHR.html (eac265c)
  • Add dummy modules when running basic tests (5fb689d)
  • fix code style issues (8cac6da)
  • Account for array-like objects in jQuery.grep (6e466af)
  • Docs: Fix various typos (ef6cd83)
  • fix support tests in ie9 (729c75f)
  • Account for Edge in originalEvent UA-sniffs (#2357, 4c3e63b)
  • Fix the expando-removal test failure in IE 8 (#2596, 4b1cff6)
  • make top of the HTML suite compliant with style guide (bc9e573)
  • Add Safari 9 support tests results (99f41c2)
  • Provide equal() arguments in correct order (actual, expected) (4503a61)
  • do not create data cache when fetching single property (0874096)
  • Increase QUnit timeout (c0a0777)
  • Really fix tests in IE 8 this time (1b48eef)
  • Disable/relax a few tests failing in Android 2.3 (#1785, 704de81)
  • add the current version of node and iojs to the travis config (dd2e027)
  • Use QUnit URL parameter parsing (fb98ea4)
  • fix support values for android (d224acb)
  • Use standard external domain name (3680689)
  • Partially use new qunit interface (#2540, 4543815)
  • Remove test/data/ua.txt (#2398, d8037c6)
  • Lower the checks rounding error (1390d07)
  • use assert syntax in restored test (56b9656)
  • don’t use deprecated argument in test declaration (b8b111e)
  • Tilt at a few style guide windmills (4365133)
  • Make basic tests work in IE 8 (f709a28)
  • Remove Edge version from the user agent (1d052bd)
  • Don’t load non-basic tests when basic module is selected (06454d1)
  • Minor updates for QUnit 1.16 compatibility (f6f8848)
  • Update QUnit (b6e31a8)
  • Fix merge conflict (d07774a)
  • Backport basic tests from master (#2505, c7d458f)
  • Keep test iframes around for assertions (06128a9)
  • Restore IE8 workarounds (Sinon timers for IE & HTML5 shiv) (0b07c65)
  • correct revert artefact (b85f32f)
  • Add .extend test for defined accessor properties (15f7920)
  • further improvements QUnit 2.0 migration (2f0cedc)
  • Correct a typo in the regex matching Safari 8 (ef332c7)
  • more style corrections (d8b7e7b)
  • Change quotes according to style guidelines (52491ae)
  • Fix CSS relative adjustment test for round-down browsers (4a8000b)
  • Add Microsoft Edge results (from Windows 10 build 10130) (546593b)
  • fix tests in accordance with new :visible behavior (cbd51c5)
  • Accommodate page changes from the QUnit HTML reporter (b747537)

Traversing

  • Don’t expose jQuery.dir & jQuery.sibling (#2512, 8c851bf)

Wrap

jQuery 3.0 and jQuery Compat 3.0 Alpha Versions Released

Posted on by

It’s been a long time since we did a major release, and you certainly deserve one. So we’re glad to announce the first alpha of jQuery 3.0!

Despite the 3.0 version number, we anticipate that these releases shouldn’t be too much trouble when it comes to upgrading existing code. Yes, there are a few breaking changes that justified the major version bump, but we’re hopeful these breakages don’t actually affect that many people. The jQuery Migrate plugin can help you to identify compatibility issues in your code as well. Your feedback on the changes in this alpha will help us greatly, so please try it out on your existing code and plugins!

There are actually two releases here. First is jQuery 3.0, which supports modern browsers and environments from IE9 forward. Second is jQuery Compat 3.0, which includes support for IE8. As an added bonus, both jQuery and jQuery Compat will include support for Yandex.Browser, a freeware browser released in 2012. You can get the files from the jQuery CDN, or link to them directly:

https://code.jquery.com/jquery-3.0.0-alpha1.js

https://code.jquery.com/jquery-compat-3.0.0-alpha1.js

You can also get the alpha versions from npm:

npm install jquery@3.0.0-alpha1

npm install jquery-compat@3.0.0-alpha1

 

Major changes

Below are just the highlights of the major new features, improvements, and bug fixes in these releases. A complete list of changes is available at the bottom of this post and on our GitHub issue tracker. On GitHub, you can additionally see the features we expect to put in later beta and final versions that have yet to land.

Simplified .show() and .hide() methods

Everyone’s mental model of jQuery’s .hide() method is that it sets display: none in CSS. Conversely, .show() clears the display so that the element shows again (assuming its parents are not hidden). Simple, right?

Well, no. There are actually many complex special cases that people asked us to “fix” over the years, which turned these methods into a convoluted confluence of principles. For example, what if the element is set to display: none in a stylesheet? jQuery would try to override that by forcing display: block on the element directly. Okay, but what if a normally block element like <li> was set to display: inline by a different stylesheet rule? How about the case where you call these methods on an element before it’s been added to the document and we don’t know what display value it will have? Determining all of that takes extra work. Sometimes it’s still just a guess that turns out to be wrong.

Since these methods add a style attribute to the element, they don’t tend to play well with techniques like responsive design where the visibility of elements may also be set by media queries. This leads to the need for jQuery handlers that listen for the orientationchange or resize events and manually hide or show parts of the page; it defeats the elegant solution that media queries were trying to implement.

You can see that jQuery was already about halfway down the path to total madness, and it didn’t make sense to complete the journey. The special cases and checks were not only complex and incomplete, but they caused significant performance issues on large pages.

So, instead, we’re experimentally defying the evolution of these methods and reverting to a simple, primordial model. This will break some code. If you have elements in a stylesheet that are set to display: none, the .show() method will no longer override that. So the most important rule for moving to jQuery 3.0 is this: Don’t use a stylesheet to set the default of display: none and then try to use .show() – or any method that shows elements, such as .slideDown() and .fadeIn() – to make it visible.

If you need an element to be hidden by default, the best way is to add a class name like “hidden” to the element and define that class to be display: none in a stylesheet. Then you can add or remove that class using jQuery’s .addClass() and .removeClass() methods to control visibility. Alternately, you can have a .ready() handler call .hide() on the elements before they are displayed on the page. Or, if you really must retain the stylesheet default, you can use .css("display", "block") (or the appropriate display value) to override the stylesheet.

We know that this is likely to be one of the most contentious and difficult changes in jQuery 3.0, so we wanted to put it out in this early release to see the effects. Please let us know how it affects your code and what you need to change in order to work with this new model.

https://github.com/jquery/jquery/issues/1767
https://github.com/jquery/jquery/issues/2057
https://github.com/jquery/jquery/issues/2308

Special case with .data() names

We have updated our .data() implementation to closer match the HTML5 dataset specification. All keys are now converted from kebab-case to camelCase, regardless of access method, and digits no longer participate in the conversion. For example, we will no longer differentiate between “foo-bar” and “fooBar”, but will differentiate between “foo-42” and “foo42”. These changes will mainly come into play when retrieving all data by calling .data() with no arguments, or when trying to access the data using a converted key (.data(“foo42”)) instead of the original (.data(“foo-42”)).

https://github.com/jquery/jquery/issues/1751

jQuery.Deferred is now Promises/A+ compatible

jQuery.Deferred objects have been updated for compatibility with Promises/A+ and ES2015 Promises, verified with the Promises/A+ Compliance Test Suite. This meant the introduction of a .catch() method and some major changes to the .then() method:

  • An exception thrown in a .then() callback now becomes a rejection value. Previously, exceptions bubbled all the way up, aborting callback execution and irreversibly locking both the parent and child Deferred objects.
  • The resolution state of a Deferred created by .then() is now controlled by its callbacks—exceptions become rejection values and non-thenable returns become fulfillment values. Previously, returns from rejection handlers became rejection values.
  • Callbacks are always invoked asynchronously. Previously, they would be called immediately upon binding or resolution, whichever came last.
  • Progress callbacks can no longer resolve Deferred objects to which they are bound.

Consider the following, in which a parent Deferred is rejected and a child callback generates an exception:

var parent = jQuery.Deferred();
var child = parent.then( null, function() {
  return "bar";
});
var callback = function( state ) {
  return function( value ) {
    console.log( state, value );
    throw new Error( "baz" );
  };
};
var grandchildren = [
  child.then( callback( "fulfilled" ), callback( "rejected" ) ),
  child.then( callback( "fulfilled" ), callback( "rejected" ) )
];
parent.reject( "foo" );
console.log( "parent resolved" );

As of jQuery 3.0, this will log “parent resolved” before invoking any callback, each child callback will then log “fulfilled bar”, and the grandchildren will be rejected with Error “baz”. In previous versions, this would log “rejected bar” (the child Deferred having been rejected instead of fulfilled) once and then immediately terminate with uncaught Error “baz” (“parent resolved” not being logged and the grandchildren remaining unresolved).

While caught exceptions had advantages for in-browser debugging, it is far more declarative (i.e. explicit) to handle them with rejection callbacks. Keep in mind that this places the responsibility on you to always add at least one rejection callback when working with promises. Otherwise, any errors will go unnoticed.

Legacy behavior can be recovered by replacing use of .then() with the now-deprecated .pipe() method (which has an identical signature).

jQuery.when has also been updated to accept any thenable object, which includes native Promise objects.

https://github.com/jquery/jquery/issues/1722
https://github.com/jquery/jquery/issues/2102

Removed special-case Deferred methods in jQuery.ajax

jqXHR object is a Promise, but also has extra methods like .abort() so that you can stop a request after it has been made.

As users increasingly embrace the Promise pattern for asynchronous work like AJAX, the idea of having special cases for the Promise returned by jQuery.ajax is an increasingly bad idea.

success, error, complete
done, fail, always

Note that this does not have any impact at all on the callbacks of the same name, which continue to exist and are not deprecated. This only affects the Promise methods!

https://github.com/jquery/jquery/issues/2084

Error cases don’t silently fail

Perhaps in a profound moment you’ve wondered, “What is the offset of a window?” Then you probably realized that is a crazy question – how can a window even have an offset?

In the past, jQuery has sometimes tried to make cases like this return something rather than having them throw errors. In this particular case of asking for the offset of a window, the answer up to now has been { top: 0, left: 0 } With this alpha of jQuery 3.0 we’re experimenting with the idea of having such cases throw errors so that crazy requests aren’t silently ignored. Please try the alpha and see if there is any code out there depending on jQuery to mask problems with invalid inputs.

https://github.com/jquery/jquery/issues/1784

.width(), .height(), .css(“width”), and .css(“height”) to return decimal values (whenever the browser does)

Previously, jQuery rounded values when retrieving width and height. Some browsers return subpixel values – such as IE and Firefox – and sometimes users need this precision when relying on these values for layout. We don’t expect this change to have a big impact on your code, but let us know if it does.

https://github.com/jquery/jquery/issues/1724

Removed deprecated event aliases

.load, .unload, and .error, deprecated since jQuery 1.8, are no more. Use .on() to register listeners.

https://github.com/jquery/jquery/issues/2286

jQuery.swap, jQuery.buildFragment, and jQuery.domManip are no longer accessible on the jQuery object

These methods were always intended for internal use only and were never documented. We are finally making them private to avoid confusion.

https://github.com/jquery/jquery/issues/2224
https://github.com/jquery/jquery/issues/2225

Animations now use requestAnimationFrame

On platforms that support the requestAnimationFrame API, which is pretty much everywhere but IE8 and IE9, jQuery will now use that API when performing animations. This should result in animations that are smoother and use less CPU time – and save battery as well on mobile devices.

jQuery tried using requestAnimationFrame a few years back but there were serious compatibility issues with existing code so we had to back it out. We think we’ve beaten most of those issues by suspending animations while a browser tab is out of view. Still, any code that depends on animations to always run in nearly real-time is making an unrealistic assumption.

.unwrap( selector )

Before jQuery 3.0, the .unwrap() method did not take any arguments. The selector parameter offers a way to be specific about which wrappers to remove.

https://github.com/jquery/jquery/issues/1744

Massive speedups for some jQuery custom selectors

Thanks to some detective work by Paul Irish at Google, we identified some cases where we could skip a bunch of extra work when custom selectors like :visible are used many times in the same document. That particular case is up to 17 times faster now!

Keep in mind that even with this improvement, selectors like :visible and :hidden can be expensive because they depend on the browser to determine whether elements are actually displaying on the page. That may require, in the worst case, a complete recalculation of CSS styles and page layout! While we don’t discourage their use in most cases, we recommend testing your pages to determine if these selectors are causing performance issues.

https://github.com/jquery/jquery/issues/2042

 

Thanks

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including Chris Antaki, Jason Bedard, Leonardo Braga, Bastian Buchholz, Anne-Gaelle Colom, David Corbacho, Brenard Cubacub, Hamish Dickson, Ben Edelman, Stephen Edgar, elas7, flexphperia, Corey Frang, Xue Fuqiao, Oleg Gaidarenko, Richard Gibson, Michał Gołębiowski, Scott González, goob, Veaceslav Grimalschi, Mu Haibao, Dan Hart, Frederic Hemberger, Nicolas Henry, Daniel Herman, Jon Hester, Victor Homyakov, Winston Howes, Daniel Husar, Essam Al Joubori, Veres Lajos, George Mauer, Richard McDaniel, Amit Merchant, Calvin Metcalf, Dave Methvin, MightyBranch, Nazar Mokrynskyi, Matthew Mueller, Martin Naumann, Alexander O’Mara, Randson Oliveira, Gilad Peleg, James Pearce, PJ, Senya Pugach, Aditya Raghavan, Chris Rebert, Aurelio De Rosa, Gabriel Schulhof, Mike Sidorov, Nick Stefan, Arthur Stolyar, Timo Tijhof, Ben Toews, Thomas Tortorini, Shivaji Varma, Arthur Verschaeve, Rick Waldron, Bin Xin, Imran M Yousuf, Jörn Zaefferer.

 

Changes

Here is the full list of changes since the last official releases (1.11.3 and 2.1.4):

 

Common to both jQuery and jQuery Compat

Ajax

  • Always use script injection in globalEval (#14757, bbdfbb4)
  • Remove jsonp callbacks through “jQuery#removeProp” method (#2323, a2ae215)
  • remove event dependency from the ajax module (4e7f34f)
  • Fix for request aborted in ajaxSend (#1775, 598ed05)
  • use anchor tag for parsing urls (#1875, b091fdb)
  • Fix cross-domain detection test for non-default port (83b038f)
  • $.post and $.get can now take an options object (#1986, 89ce0af)
  • simplify one ajax call and add explanatory comment (0ac28ed)
  • make jQuery#load “type” field explicit (4ef120d)
  • replace “jqXHR.complete” callback with “always” (97ef1f2)
  • remove deprecated extensions from ajax promise (#2084, 9d1b989)
  • remove use of jQuery#each second argument (a4715f4)
  • remove “onunload” event handler (a117dd0)
  • Remove remnants of the load event alias handling (38a6697)

Attributes

  • add SVG class manipulation (#2199, 20aaed3)
  • return null when attribute does not exist (#2118, aaeed53)
  • Use the option val hook in select val hook and simplify it (#1902, f6302b0)
  • remove unnecessary element null check (55ac56a)
  • fix failing test for new return value (5dc4616)
  • revert returning null for non-elements (7632b74)
  • revert returning null for non-existant attributes (2905961)

Build

  • update Sizzle to 2.0.0 (bcca4f0)
  • Update grunt-contrib-jshint (1556c46)
  • remove bower.json lint target (285cfbf)
  • add mailmap entry (3ec73ef)
  • Update the license attribute (#2331, 8e92e1e)
  • drop bower; use npm for front-end deps (#15186, e1949f4)
  • update front-end dependencies (8356948)
  • update node dependencies barring jscs (8e3a0ce)
  • update grunt-jscs-checker and pass with the new rules (c869a1e)
  • update requirejs dependency to 2.1.17 (#2290, a644101)
  • update source map options for the new grunt jshint (269a27c)
  • bower.json: remove moot `version` field (61e21a4)
  • fix broken assertions caused by QUnit update (8b6aeae)
  • Update commitplease dev dependency (39b7606)
  • remove deprecated JSHint options (34da7d5)
  • update AUTHORS.txt (8f13997)
  • Upgrade to commitplease 2.0.0 (5bc1ddc)
  • Update QUnit to latest (1.17.1) (2d5c5d2)
  • update version to 3.0.0-pre (7a607c5)
  • Move test to appropriate module (fbdbb6f)
  • Fix various typos (dc4b914)
  • Speed up the Travis build (31f4f8e)
  • Remove empty define({}) from build output (#1768, 2c1b556)
  • Remove npm from dependencies (b92acf7)
  • Upgrade to grunt-bowercopy 1.0.0 (323e82c)
  • Remove unused Sizzle test files (8d11310)
  • fix tests in AMD mode (6051609)
  • Move all external libraries to external directory (c5d9d88)
  • account for version labels in Sizzle versions (#1939, 78ac753)
  • update node dependencies (9101704)
  • Sizzle version labels must start with a dash (d6c97ab)
  • Don’t assume the browser environment; smoke test on Node w/ jsdom (#1950, 76df9e4)
  • Remove dates from copyright notice (66e1b6b)
  • Specify valid components for commit messages (0c9d018)
  • ignore test dependencies for npm install (35f8e15)
  • update Sizzle to 1.11.1 and include license (c0b23e2)
  • update Sizzle (#2042, #1969, 3a0dd5a)
  • update grunt-bowercopy (712e78c)
  • Update license (4f776e5)
  • Sanctify the component name status of Wrap (a4133ff)
  • Update native-promise-only (again) (f5aa89a)
  • Rearrange grunt/npm tasks into a build/dist/test pattern (bb928bd)
  • Update native-promise-only (0065e1f)
  • save sinon update for later (#2160, 98c25b7)

Callbacks

Core

  • Return empty array instead of null for parseHTML(“”) (#1997, 4116914)
  • use document.implemenation.createHTMLDocument in jQuery.parseHTML (58c2460)
  • Follow the AMD specification for define (892625b)
  • Throw an error on $(“#”) rather than returning 0-length collection (80022c8)
  • allow init to accept an alternate rootjQuery for migrate’s sake (#2101, 7a6931d)
  • remove unnecessary support test for createHTMLDocument (5923282)
  • pass empty string to createHTMLDocument to appease IE (31c7d7f)
  • revert addition of createHTMLDocument. Thanks, Safari 8. (b779831)
  • Update tested jsdom, drop obsolete workarounds (#2153, 06f6cd1)
  • re-introduce createHTMLDocument in parseHTML; Safari 8 left out (cfe468f)
  • Standardize indexOf comparisons (53aa87f)
  • remove custom ready event (#2264, c252c5f)
  • Consistently use local reference to access() (2fb719e)
  • Remove deprecated context and selector properties (#1908, 0ea8c32)
  • remove isArraylike check for nodes (#2238, 436f0ae)
  • add support to tag-hyphenated elements (534f130)
  • Use window.setTimeout & friends instead of global equivalents (#2177, 219c749)
  • Drop size and andSelf methods (#1749, f110360)
  • Drop strundefined variable (29838b6)
  • Make jQuery objects iterable (#1693, bb026fc)
  • add workaround for iOS JIT error in isArrayLike (#2145, 1541664)
  • Test all factory use cases from intro.js (#2181, ab40725)
  • Switch from modules to just window.setTimeout etc. (842958e)
  • Align branches: remove an unused variable, add comments (f6de5a9)
  • simplify “each” stylesheet iteration test (fcb6c4d)
  • Simplify and speed up .each (eeda11c)
  • organize prop & attr code to be similar (5153b53)
  • change jQuery.each and jQuery#each signatures (#2090, 2380028)

CSS

  • CSS:Event: simplification of native method signatures (85577a3)
  • Fix the “sanity check” test (995f707)
  • Remove non-functional unit test for negative margin (4ab7431)
  • Add an integration test for issue gh-1764 (8887106)
  • Remove use of getDefaultComputedStyle (#15227, 274feb5)
  • Use pre-defined displays for html and body (a772418)
  • Correct typo in the comment (7e09619)
  • Removed redundant “to the number” in comment (895ea68)
  • fix :visible/:hidden selectors for inline element w/ content (#2227, 79bcb29)
  • Support relative adjustment in any applicable unit (#1711, 9b03f6d)
  • elements are hidden when either offsetWidth or offsetHeight is zero (#10406, #13132, 10399dd)
  • Ignore the CSS cascade in show()/hide()/etc. (#1767, #2071, 86419b1)
  • Fix the pixelMarginRight support test in Android 2.3 (cdfc2d0)
  • Clean up memory leak in reliableMarginRight (#1795, 7d15b4d)
  • Don’t cache unrecognized CSS property names (#2015, d471842)
  • Don’t name the anonymous swap function (0019a46)
  • make the getStyles function more readable (3a0d582)
  • Work around an IE11 fullscreen dimensions bug (#1764, 90d828b)
  • Add unit tests for negative margins and positioning (1b932bb)
  • simplify “defaultDisplay” module (c62486f)
  • Make .css(“width”) & .css(“height”) return fractional values (#1724, b60b26e)
  • Don’t expose jQuery.swap (#2058, bb4d888)
  • Improve a comment explaining IE11 fullscreen bug (8e4aac8)

Data

  • do not include digits when camelCasing (#1751, 2862a07)
  • always camelCase keys in .data() (#2257, 0e79098)
  • Use a PDF object instead of a Java applet for acceptData testing (#1938, 087d280)
  • camelCasing should not ignore case (#2070, 172cad8)

Deferred

Dimensions

  • allow modification of coordinates argument (#1848, f7e60dc)

Docs

  • 1.x-master branch -> compat branch; 2.x branch -> master branch (758fd6c)
  • correct grunt command in README.md (#1850, 9d6beac)
  • remove redundant instruction from the readme (#2359, 3c92770)
  • Clarify custom build instructions (a3779bc)

Effects

  • Adding unit tests for jQuery.Animation (b3b2d6c)
  • Reintroduce use of requestAnimationFrame (#15147, 72119e0)
  • add tests for jQuery.easing._default in Animation and Tween (6d7ef56)
  • set default easing using jQuery.easing._default (#2219, 5f2ea40)
  • Add tests for jQuery.Tween (cdaed15)
  • Improve raf logic (708764f)

Events

  • remove preDispatch hook & simplify “simulate” signature (3655c4e)
  • remove guard for falsy handler argument of jQuery#on method (fac67a9)
  • add support comment (9db9316)
  • correct support comment (361a0d5)
  • HTML5 drop events inherit from MouseEvent (#2009, d7e5fce)
  • Fully clean up events in unit test (4467ed6)
  • Empty namespaces should be uneventfully ignored (8653068)
  • remove outdated originalEvent hack (6df669f)
  • Remove fake originalEvent from jQuery.Event.simulate (#2300, 7475d5d)
  • fix incorrect window bug with scrollTop/Left in iframes (#1945, d21edb5)
  • remove deprecated event aliases (#2286, 0705be4)
  • Add a note about a mouseenter bug in Chrome (a5e1c9b)
  • Restore the `constructor` property on jQuery.Event prototype (#15090, b807aed)
  • Copy detail property to jQuery.Event on native events (#1867, d9ed166)
  • Remove an internal argument to the on method (04a2969)
  • Normalize mouse event properties in drag events (#1925, 97cf528)
  • provide verbose comment for focus(in | out) & rename support prop (c074006)
  • remove redundant guards for the event methods (#2047, a873558)

Manipulation

Misc

  • Drop support for older browsers; update support comments (740e190)
  • Need for speed removed by 9ad6e7e (ff928f5)
  • Mac OS is now OS X, thanks @xfq (d30c482)

Offset

  • remove ownerDocument check in offset getter (#2115, 6176567)
  • Round offset value for the sake of floating errors (#2147, 62ae2d0)
  • return zeros for disconnected/hidden elements (#2310, 40dcc76)
  • Fix .offset() to correctly work with ShadowDOM (#1784, 1617479)
  • account for scroll when calculating position (#1708, 2d71594)
  • don’t run scrollTop/scrollLeft iframe test in Android 2.3 & 4.0 (#1981, 0c46643)
  • return before getBoundingClientRect to avoid error in IE8-11 (0e4477c)
  • add tests for hidden elements + scroll (b041242)
  • simplify jQuery#offsetParent method (74ae544)

README

  • Fix punctuation in tile (df62159)
  • Fix minor style issues. Thanks @MightyBranch! (edfc94d)
  • update the Homebrew site address (b410b15)
  • various text fixes (31b63fc)
  • Update the description of the deprecated module (1d75273)
  • Improve build instructions (2e9c1ea)

Release

  • update AUTHORS.txt (e905dcd)
  • Remove copying of jquery-latest files (c34ed46)
  • properly set the dist remote when it’s a real release (c44dd77)
  • bower.json is actually generated from scratch (61224f5)
  • Distribute files to distribution repo (#1869, #1673, #2045, 26eca14)
  • dist can be run during a test (aae998b)
  • push dist to same remote as project (1ba45fc)
  • remove sourcemap comment from all copies of minified file (#1707, a76c781)
  • fix CDN archive creation (#1940, e0673df)

Selector/Sizzle

  • add jQuery.uniqueSort; deprecate jQuery.unique (#2228, e1090c3)
  • add test for jQuery.unique() alias (add85af)
  • Remove “#” exception for identifier tokens (86e62d8)
  • update to 2.1.1 (7602dc7)

Support

  • Re-organize browser order, add Safari 8 (43faf6d)
  • Correct iOS 8 support test results, re-arrange entries (ce308e2)

Tests

  • Update QUnit (6748ba3)
  • Minor updates for QUnit 1.16 compatibility (26276a3)
  • Accommodate page changes from the QUnit HTML reporter (3c13f4c)
  • Increase QUnit timeout (ff18d8e)
  • Tilt at a few style guide windmills (906caeb)
  • Correct a typo in the regex matching Safari 8 (c17543f)
  • Add Microsoft Edge results (from Windows 10 build 10130) (8e111df)
  • Remove Edge version from the user agent (5a1217e)
  • Remove test/data/ua.txt (#2398, e831856)
  • fix tests in accordance with new :visible behavior (16713fb)
  • add the current version of node and iojs to the travis config (bd9a138)
  • Expand CSS relative adjustment tolerance for IE (e22ef5d)
  • Fix CSS relative adjustment test for round-down browsers (48be675)
  • Lower the checks rounding error (a44cfa0)
  • make top of the HTML suite compliant with style guide (8356281)

Wrap

  • Support .unwrap( selector) for selective unwrapping (#1744, 7b09235)

 

jQuery 3.0 Only

Ajax

  • Remove workaround for IE6/7 (e519098)
  • simplify jQuery.parseXML method (5a0867d)

Build

  • use different versions of jsdom for Node and iojs testing (#2266, 5c3101f)
  • Refactor Node smoke tests (9c8a3ec)
  • Moved JSHint directives to .jshintrc file (15a609f)

CSS

  • save 20 bytes in css/support (45ec73f)
  • Collapse a double if statement into one (7855a1a)
  • Restore the hack to get pixels for .css(‘width’) etc. (3747cc6)

Data

  • shave off a couple of bytes (6f65f5f)
  • avoid Object.defineProperties for nodes (#1728, 95fb798)
  • avoid non-alphanumeric chars in expando properties (0cdec79)
  • updates to element[expando] cache (222ac3a)
  • move element cache to element[expando] (#1734, d702b76)
  • remove some unused code (764dc94)
  • remove the expando when there’s no more data (#1760, 56bb677)
  • speed up $.fn.data() for camel-cased key (#1941, 72c4a06)
  • restore explicit data removal of private data in cleanData. (#2127, 332fd94)
  • Drop the tests relying on applets (#1938, 95c0a10)

Docs

  • Add info about Sizzle not being excludable on the compat branch (#2184, 062b526)
  • Fix README uppercase (b50e0f2)

Manipulation

  • Tolerate XMLNode host object input to getAll (#15151, 1ae025e)
  • Check state lost if the name is set for Android 4.0-4.3 (1bbb678)

Misc

  • Adjust comments & docs to dropping IE * Misc: Update all references to bugs.jquery.com (#1681, 3e89a53)
  • Remove leftover -moz-box-sizing in tests (e81b258)

Offset

  • Simplified a conditional (4287442)
  • don’t run scrollTop/scrollLeft iframe test in mobile Safari (4ab8603)

README

  • Add selector-native.js link. Thanks @randsonjs! (cfe2eae)

Tests

  • Remove a trailing comma for compatibility with the compat branch (dc8ba6a)

 

jQuery Compat 3.0 only

Ajax

  • Add support comment and fix code style issue (e38a94a)
  • Run the PATCH test only in IE8 on TestSwarm (#1994, 2524da0)
  • move explanatory comment to appropriate place (04fc801)
  • Use the native XHR for all non-local requests in IE9+ (#1684, 61f812b)
  • Rename Spartan to Edge in a comment (8d88cd5)
  • Fix the XHR fallback logic for IE8 (bd699cb)

Attributes

  • Use typeof check for getAttribute method (075da30)
  • don’t test SVG CSS-class manipulation in IE8 (57fb2dc)
  • fix IE8 issues (f2bcf87)

Build

  • Point to files from the compat branch, not master (b7663ea)
  • Put “jQuery Compat” in banners in built files (8cd6875)
  • 1.x-master -> compat (2912ddd)
  • Add “timers_ie.js” file back to the repo (31e6697)
  • append “+compat” to tag version and jQuery.fn.jquery (#2269, d18b645)
  • Correct indentation issue (d0f27a7)

Callbacks

  • Change broken url to wayback one (e4cbc97)

Core

  • Align code in intro.js with master (fe2a584)

CSS

  • Add a support test for the hack for .css(‘marginRight’) etc. (25bc680)
  • Fix get upper case alpha opacity in IE8 (#1705, c5e8e12)
  • simplify hack of css getter for the computed values (dac716c)
  • fix dependency order for amd (e185aa3)

Data

  • use removeAttribute in cleanData to bypass Chrome bug (#1664, 9d1d90e)

Deferred

  • pass lint in new catch tests (203979d)

Docs

Effects

Events

  • Add reference to data module (2866da9)
  • correct an unfinished comment (ac23f91)

Manipulation

  • don’t test data-URI with script element in IE8 (503e545)
  • Plug an IE8 memory leak in noCloneEvent feature detect (#1840, faf295a)
  • Update html5shiv elements (#15241, a953389)
  • blacklist IE8 from running tests for tag-hyphenated elems (87bb713)

Misc

Offset

  • allow offset setter to throw for disconnected elements (#2114, dc49f62)
  • getBounding doesn’t return width/height in IE8. Fixes test. (3b1de11)
  • fix iframe scrollTop/Left test for IE8 (d632699)
  • fix iframe scrollTop/Left test for IE8 and iPhone (62a333e)
  • revert to jQuery.contains for IE8’s sake (compat only) (6df3990)
  • no need to check for ownerDocument (523de77)

Tests

  • Restore IE8 workarounds (Sinon timers for IE & HTML5 shiv) (0b07c65)

Traversing

  • simplify jQuery#contents method (7230df1)

jQuery 1.11.3 and 2.1.4 Released – iOS Fail-Safe Edition

Posted on by

Here we are again. It’s too late for April Fools, so you can believe us when we tell you that we have two new patch releases for you: jQuery 1.11.3 and 2.1.4.

These releases include a hot-fix for a rare bug in iOS 8.2 and 8.3. This is the only change. As with 1.11.2 and 2.1.3, we do not anticipate any issues when upgrading. However, if you do encounter bugs in upgrading from the previous versions, please let us know.

You can include these files directly from the jQuery CDN if you like, or copy them to your own local server. The 1.x branch includes support for IE 6/7/8 and the 2.x branch does not.

https://code.jquery.com/jquery-1.11.3.js

https://code.jquery.com/jquery-2.1.4.js

These updates are already available as the current versions on npm and Bower. Information on all the ways to get jQuery is available at https://jquery.com/download/. Please keep in mind that public, third-party CDNs receive their copies today and it can take a few days to post the files. If you’re anxious to get started, our CDN is always available.

Many thanks to all of you who participated in this release by testing, reporting bugs, or submitting patches, including John-David Dalton, Michał Gołębiowski, Oleg Gaidarenko, Richard Gibson, Dave Methvin, Benjamin Poulain, and Oz Solomon.

Thanks for all your support, and we look forward to showing you all we have in store for jQuery 3.0!