title: When exactly is `componentDidMount` fired?
body: <p>This is a recurring problem I have with React. The <code>componentDidMount</code> method is guaranteed to be fired when the component is rendered for the first time so it seems like a natural place to take DOM measurements like heights and offsets.
  However, many times I receive wrong style readings at this point of the component's lifecycle. The component <strong>is</strong> in the DOM, when I break with the debugger, but it's not yet painted on the screen. I get this problem with elements that have width/height set to 100% mostly.
  When I take measurements in <code>componentDidUpdate</code> - everything works fine, but this method will not fire at the initial render of the component.</p>
  
  <p>So my question is - when exactly is <code>componentDidMount</code> fired because it's obviously not fired after all the browser paints are done.</p>
  
  <p><strong>EDIT:</strong> 
  <a href="https://stackoverflow.com/questions/30978911/react-cant-get-correct-width-of-element-after-render">This Stackoverflow issue</a> deals with the same subject:</p>
  
  <p>It also references <a href="https://github.com/facebook/react/issues/2659" rel="noreferrer">this github conversation</a> that explains what happens</p>