When exactly is `componentDidMount` fired?

Inside a react component tree, componentDidMount() is fired after all children components have also been mounted. This means, that any component’s componentDidMount() is fired before its parent has been mounted. So if you want to measure DOM position and sizes etc, using componentDidMount() of a child component is an unsafe place/ time to do this. … Read more

React vs ReactDOM?

React and ReactDOM were only recently split into two different libraries. Prior to v0.14, all ReactDOM functionality was part of React. This may be a source of confusion, since any slightly dated documentation won’t mention the React / ReactDOM distinction. As the name implies, ReactDOM is the glue between React and the DOM. Often, you … Read more