You can delegate an event handler for a common ancestor.
However, it will work only if this element has this particular class, because the check is performed when the event is clickactually triggered (and not when the event handler is connected).
Example here
$(document).on('click', '.changeBG', function(){
$(this).css('background-color', 'red');
});
document . , , , , , document.
.off() , .
click click.changeBG:
$('.changeBG').on('click.changeBG', function(){
$(this).css('background-color', 'red');
});
.off('click.changeBG'):
$('.changeBG').removeClass('changeBG').off('click.changeBG');