Releases: jquery/jquery-migrate
3.6.0
What's Changed
This release prepares jQuery 3.x apps better for a future migration to jQuery 4.x. It also drops support for jQuery 4.x - once you do update to jQuery 4.x, you should load jQuery Migrate 4.x.
Core
- Fill in & warn against $.fn.{push,sort,splice} by @mgol in #529
- Fill in & warn against jQuery.proxy by @mgol in #530
- Fix the selector module, make CI green by @mgol in #552
- Remove support for jQuery 4.x by @mgol in #554
- Patch push, sort & splice in jQuery >=3.7.0 by @mgol in #568
- Warn against jQuery.now & jQuery.camelCase by @mgol in #600
Ajax
Attributes
Data
- Patch camelCase behavior of $.fn.data, warn about Object.prototype by @mgol in #559
- Patch
$._data&$._removeDataas well, add more tests by @mgol in #570
Deferred
- Fill in & warn
jQuery.Deferred.getStackHookby @mgol in #528 - Don't warn on setting getStackHook to the getErrorHook value by @mgol in #578
Event
Selector
Others
- Docs: Add an entry for
legacy-self-closed-tagsinwarnings.mdby @mgol in #526 - Docs: Tweak README.md & warnings.md - update removal info by @mgol in #596
- Docs: Indicate which deprecated APIs are removed in 4.0; tweak a comment by @mgol in #606
- Tests: Migrate test runner to jquery-test-runner by @timmywil in #560
- Build: Test more browsers and jquery versions in pull requests by @mgol in #551
Full Changelog: 3.5.2...3.6.0
4.0.0-beta.2
The only change compared to 4.0.0-beta.1 is fixing peerDependencies so that jQuery Migrate 4.0.0-beta.2 can be installed alongside jQuery 4.0.0-beta.2 or newer. 4.0.0-beta.1 required a stable jQuery 4.0.0 or newer which doesn't exist yet.
Read the 4.0.0-beta.1 release notes for more details.
4.0.0-beta.1
The first jQuery Migrate pre-release compatible with jQuery 4.0.0-rc.1.
Major changes:
-
Core: Remove patches for breaking changes in jQuery 3.0.0 or older (gh-472, gh-555)
The
self-closed-tagspatch remains, despite being a breaking change in jQuery
3.5.0, not 4.0.0. There are a few reasons for that:- It's an exception that a breaking change arrived in a non-major version bump.
Some people may be upgrading from jQuery 3.4.0 or older and it's good to
make it work for them. - The patch is disabled by default, so the concern of people on newer jQuery
3.x upgrading to jQuery 4.x with Migrate 4.x getting patches restoring
behavior from an version older than the pre-upgrade one does not exist. - This was a pretty big break, it may help people update if we still support
it.
- It's an exception that a breaking change arrived in a non-major version bump.
-
Core: Don't reimplement deprecated but not removed APIs (gh-472, gh-555)
This will save space and avoid potential divergence from Core.
Also, simplify the
deferred.pipepatch. -
Core: Use
console.infofor deprecations without removals (gh-472, gh-555)Also:
- Group
warnings.mdby this type. - Rename
jQuery.migrateWarningstojQuery.migrateMessages. - Rename
jQuery.migrateDeduplicateWarningsto
jQuery.migrateDeduplicateMessages. - Adding "info" versions of some internal APIs.
- Group
-
Core: Provide a package.json exports setup inspired by jQuery Core (gh-524, gh-566)
The Migrate setup is simpler than Core as it doesn't have the slim or factory
versions, but the core ideas are similar. -
Core: Don't warn just on access of
jQuery.fn.push, etc., but when it's called (gh-571) -
Data: Patch & warn about props from Object.prototype in data objects (gh-561, gh-559)
-
Event: Patch jQuery.event.global (gh-574)
-
Event: Patch jQuery.event.special's prototype (gh-573, gh-542)
Allow to use common
Object.prototypeproperties onjQuery.event.specialbut
warn as well.