mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Update conditional-rendering.md (#8636)
Stating the fact that component lifecycle methods will still fire as normal even though you return null from the render method.
This commit is contained in:
committed by
Dan Abramov
parent
5d153c9dbe
commit
3baa47ca7b
@@ -238,3 +238,5 @@ ReactDOM.render(
|
||||
```
|
||||
|
||||
[Try it on CodePen.](https://codepen.io/gaearon/pen/Xjoqwm?editors=0010)
|
||||
|
||||
Returning `null` from a component's `render` method does not affect the firing of the component's lifecycle methods. For instance, `componentWillUpdate` and `componentDidUpdate` will still be called.
|
||||
|
||||
Reference in New Issue
Block a user