title: In vue.js 2, measure the height of a component once slots are rendered
body: <p>I am looking for a way to read the height (clientHeight) of a component after its slots are rendered (in the DOM) and then set the result to a reactive data for further computations.</p>
  
  <p>According to the documentation of the <code>updated</code> hook:</p>
  
  <blockquote>
    <p>The component’s DOM will have been updated when this hook is called, so you can perform DOM-dependent operations here</p>
  </blockquote>
  
  <p>... It's ok until then, but the documentation also states:</p>
  
  <blockquote>
    <p>However, in most cases you should avoid changing state inside the hook</p>
  </blockquote>
  
  <p>... It seems that this is not prohibited to set reactive data in the <code>updated</code> hook.</p>
  
  <p>The result is very instable, sometimes I get the <code>clientHeight</code> after slots are rendered, and sometimes before they are rendered.</p>
  
  <p>It seems that 'updated' hook is called at the right moment but changing the reactive data in this hook does not work systematically.</p>
  
  <p>test: <a href="https://jsfiddle.net/4wv9f052/5/" rel="nofollow noreferrer">https://jsfiddle.net/4wv9f052/5/</a></p>