Skip to content

Latest commit

 

History

History
30 lines (22 loc) · 704 Bytes

no-undelegate.md

File metadata and controls

30 lines (22 loc) · 704 Bytes

no-undelegate

Disallows the .undelegate method. Prefer .off/EventTarget#removeEventListener.

⚠️ This rule is deprecated. Use no-delegate instead.

Rule details

❌ Examples of incorrect code:

$( 'div' ).undelegate();
$div.undelegate();
$( 'div' ).first().undelegate();
$( 'div' ).append( $( 'input' ).undelegate() );

✔️ Examples of correct code:

undelegate();
[].undelegate();
div.undelegate();
div.undelegate;

Resources