We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 62979b4 commit 8b9f7eaCopy full SHA for 8b9f7ea
1 file changed
react/component/src/lifecycle/README.md
@@ -1,4 +1,5 @@
1
# 生命周期
2
+
3
React 是一个由虚拟 DOM 渲染成真实 DOM 的过程,这个过程称为组件的生命周期。React 把这个周期划分为三个阶段,每个阶段都提供了 will 和 did 两种处理方式,will 是指发生前,did 是指发生后。
4
- Mounting:组件渲染过程
5
- componentWillMount()
@@ -13,6 +14,7 @@ React 是一个由虚拟 DOM 渲染成真实 DOM 的过程,这个过程称为
13
14
- 这个阶段没有对应的 did 方法
15
16
## Mounting
17
18
指首次渲染或者组件从 DOM 中移除后再次重新渲染,后者场景不会执行 getDefaultProps
19
### 执行顺序
20
1. getDefaultProps
@@ -161,4 +163,7 @@ var UnmountingComponent = React.createClass({
161
163
162
164
ReactDOM.render(<UnmountingComponent/>, document.getElementById('div3'));
165
```
-[效果预览](https://wscats.github.io/react-tutorial/react/component/src/lifecycle/lifecycle.html)
166
167
+### 效果预览
168
169
+- [组件的生命周期](https://wscats.github.io/react-tutorial/react/component/src/lifecycle/lifecycle.html)
0 commit comments