title: How to get parent element height in my scenario?
body: <p>I am trying to get parent element's height in my directive.</p>
  
  <p>I have something like</p>
  
  <pre><code>(function(window, angular) {
      var app = angular.module('myApp');
      app.directive('testElem', [
          function() {
              return {
                  restrict: 'A',
                  template:'&lt;a class="button"&gt;&lt;/a&gt;',
                  link: function(scope, element) {                        
                      var height = angular.element(element).parent().height();
                      console.log(height); 
                      //the height is 0 because not all item.description are   
                      //rendered
                  }
              };
          }
      ]);
  })(window, angular);
  </code></pre>
  
  <p>html</p>
  
  <pre><code>&lt;div id="container"&gt;
      &lt;div ng-repeat="item in items"&gt;
          {{item.description}}
      &lt;/div&gt;
      &lt;a test-elem href="#"&gt;&lt;/a&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I am trying to get the height of <code>#container</code> AFTER I have all the <code>{{item.description}}</code> rendered in my page. My current codes will get me height of it's parent as soon as the doms are finished which has no item.description. </p>
  
  <p>Thanks for the help! </p>