title: Problem with checking if div is empty works only in the begining
body: <p>I met a problem while trying to check if <code>p</code> in <code>div</code> is empty. These spans are being removed by users clicking on them and I want to alert something when they all dissapear. I tried this Jquery script below but it only works in the begining when I load page.</p>
  <pre><code>html
  &lt;div class=&quot;skladniki&quot;&gt;
  &lt;p&gt;
  &lt;span&gt; example &lt;/span&gt;
  &lt;span&gt; example &lt;/span&gt;
  &lt;span&gt; example &lt;/span&gt;
  &lt;span&gt; example &lt;/span&gt;
   &lt;/p&gt;
  &lt;/div&gt;
  </code></pre>
  <p>jquery:</p>
  <pre><code> &lt;script&gt;
         $(document).ready(function () {
  
                if ($('.skladniki').is(':empty')){
    console.log(&quot;elo&quot;);
  }
         });
         &lt;/script&gt;
  </code></pre>