-
Notifications
You must be signed in to change notification settings - Fork 20.6k
Core: Drop support for Edge Legacy (i.e. non-Chromium Microsoft Edge) #4792
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@@ -543,7 +543,7 @@ jQuery.extend( { | |||
if ( s.crossDomain == null ) { | |||
urlAnchor = document.createElement( "a" ); | |||
|
|||
// Support: IE <=8 - 11+, Edge 12 - 17 only | |||
// Support: IE <=8 - 11+ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed mentions of Edge from support comments as well. Among other things, this is because many IE workarounds are now hidden behind an isIE
check so a support comment mentioning Edge would be confusing as Edge wouldn't execute that code.
IE is quite special here as that's the only browser which we detect as a browser to work around its bugs instead of running support tests.
Travis fails because tests on Firefox ESR are run on version 68 at the moment. That version doesn't support the |
return jQuery.contains( elem.ownerDocument, elem ) || | ||
elem.getRootNode( composed ) === elem.ownerDocument; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reorganizing the definitions decreased the gzipped size a bit.
Also, restrict some workarounds that were applied unconditionally in all browsers to run only in IE now. This slightly increases the size but reduces the performance burden on modern browsers that don't need the workarounds. Also, clean up some comments & remove some obsolete workarounds. Fixes jquerygh-4568
Both IE & Edge Legacy need the workaround of calling `setDocument()` in an `unload` handler to avoid "permission denied" errors. However, due to not being possible to feature-detect this issue, the handler has been applied in all browsers for windows different than the one in which jQuery was loaded. jQuery 4.0, which drops Edge Legacy support, guards this workaround with a `document.documentMode` check. This won't work in the 3.x line due to still supporting Edge Legacy but we can check for `document.documentElement.msMatchesSelector` instead as that API is supported in IE 9+ and all Edge Legacy versions. Fixes jquerygh-5281 Ref jquerygh-4792
Both IE & Edge Legacy need the workaround of calling `setDocument()` in an `unload` handler to avoid "permission denied" errors. However, due to not being possible to feature-detect this issue, the handler has been applied in all browsers for windows different than the one in which jQuery was loaded. jQuery 4.0, which drops Edge Legacy support, guards this workaround with a `document.documentMode` check. This won't work in the 3.x line due to still supporting Edge Legacy but we can check for `document.documentElement.msMatchesSelector` instead as that API is supported in IE 9+ and all Edge Legacy versions. Fixes gh-5281 Closes gh-5282 Ref gh-4792
Summary
Drop support for EdgeHTML (i.e. non-Chromium Microsoft Edge).
Also, restrict some workarounds that were applied unconditionally in all
browsers to run only in IE now. This slightly increases the size but reduces
the performance burden on modern browsers that don't need the workarounds.
Also, clean up some comments & remove some obsolete workarounds.
Fixes gh-4568
-255 bytes 🎉
Checklist
New tests have been added to show the fix or feature worksIf needed, a docs issue/PR was created at https://github.com/jquery/api.jquery.com