Can you force a component to re-render without calling setState? in REACT

Practice



By default, when your component's state or props change, your component will re-render. If your

render()
method depends on some other data, you can tell React that the component needs to re-render by calling its
forceUpdate()
.
component.forceUpdate(callback)
 
It is recommended that you avoid using forceUpdate()
at all and read only from this.props

Comments

To leave a comment

If you have any suggestion, idea, thanks or comment, feel free to write. We really value feedback and are glad to hear your opinion.
To reply

Lectures and tutorial on "Scripting client side JavaScript, jqvery, BackBone"

Terms: Scripting client side JavaScript, jqvery, BackBone