title: AngularJS watch DOM change
body: <p>I have one <code>auto-carousel</code> directive which iterates through the linked element's <strong>children</strong>.</p>
  
  <p>The children however are not yet loaded in the DOM, because their <code>ng-if</code>s expressions have not been parsed yet.</p>
  
  <p>How can I make sure the parent directive knows there have been changes to it's DOM tree?</p>
  
  <pre><code>        &lt;ul class="unstyled" auto-carousel&gt;
            &lt;li class="slide" ng-if="name"&gt;{{name}}&lt;/li&gt;
            ...
            &lt;li class="slide" ng-if="email"&gt;{{email}}&lt;/li&gt;
          &lt;/ul&gt;
  </code></pre>
  
  <p>I could use <code>$timeout</code> but that feels unreliable. I could also use <code>ng-show</code> instead of <code>ng-if</code> but that does not answer the question and not what I need.</p>