mirror of
https://github.com/jquery/jquery-ui.git
synced 2026-04-20 03:02:41 -04:00
Core: Added comment about why we use triggerHandler instead of trigger in $.fn.remove.
This commit is contained in:
@@ -13,7 +13,8 @@
|
||||
|
||||
var _remove = $.fn.remove;
|
||||
$.fn.remove = function() {
|
||||
// TODO: add comment about why we can't use .trigger()
|
||||
// Safari has a native remove event which actually removes DOM elements,
|
||||
// so we have to use triggerHandler instead of trigger (#3037).
|
||||
$("*", this).add(this).each(function() {
|
||||
$(this).triggerHandler("remove");
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user