Created
May 3, 2016 20:13
-
-
Save awestmoreland/4ae7a6077f35a6d5c5b3d23a733baa24 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Only works for existing button.remove elements | |
$('#broken button.remove').on('click', function(){ | |
$(this).remove(); | |
}); | |
// Works for existing button.remove elements, and new ones added dynamically | |
$('#working').on('click', 'button.remove', function(){ | |
$(this).remove(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment