just before sounds better that 'immediately before' (#611)

This commit is contained in:
G Akshay
2018-02-12 01:23:39 +05:30
committed by Dan Abramov
parent 158a6285b1
commit c66011b32d

View File

@@ -248,7 +248,7 @@ We do not recommend doing deep equality checks or using `JSON.stringify()` in `s
componentWillUpdate(nextProps, nextState)
```
`componentWillUpdate()` is invoked immediately before rendering when new props or state are being received. Use this as an opportunity to perform preparation before an update occurs. This method is not called for the initial render.
`componentWillUpdate()` is invoked just before rendering when new props or state are being received. Use this as an opportunity to perform preparation before an update occurs. This method is not called for the initial render.
Note that you cannot call `this.setState()` here; nor should you do anything else (e.g. dispatch a Redux action) that would trigger an update to a React component before `componentWillUpdate()` returns.