getDefaultProps 初始化Props属性,这个Props来自其他组件传递过来的知识
getlnitialState 初始化当前组件的状态
componentWillMount 组件初始化之前会调用这个方法
render 渲染页面上的组件,必须会有的
componentDidMount 组件插入后调用的方法
componentWillReceiveProps 父组件的传递所调用的方法
shouldComponentUpdate 组件的更新
componentWillUpdate 组件更新之前
componentDidUpdate 组件更新之后
componentWillUnmount 组件的销毁
react生命周期
最新推荐文章于 2024-04-07 10:15:00 发布