生命周期问题
父组件挂载三次子组件:生命周期函数执行流程真实的是这样的(对比标箭头的地方)
super constructor
super componentWillMount
super render
->child componentWillMount
->child render
->child componentWillMount
->child render
->child componentWillMount
->child render
->child componentDidMount
->child componentDidMount
->child componentDidMount
super componentDidMount
为什么不是这样的?
super constructor
super componentWillMount
super render
->child componentWillMount
->child render
->child componentDidMount
->child componentWillMount
->child render
->child componentWillMount
->child render
->child componentDidMount
super componentDidMount