JSFiddle - React, Tailwind, and code Playground
HTML
<div class="serie">1</div>
<div class="serie excluded">2</div>
CSS
div {
height: 100px;
width: 100px;
float: left;
margin: 5px;
border: 1px solid black;
}
JavaScript
$(document).ready(function() {
// Works!
// $('.serie').not('.excluded').click(function() {
// alert('click');
// });
// Works!
// $('.serie:not(.excluded)').click(function() {
// alert('click');
// });
// Doesn't work ...
$('.serie').not('.excluded').live('click', function() {
alert('click');
});
// Works!
// $('.serie:not(.excluded)').live('click', function() {
// alert('click');
// });
});