40 ms·
Sorry, can you elaborate? How are lifecycle methods useful for updating the screen when data changes? Component lifecycle methods are componentWillMount, compon
by interlocutor 10y ago
Sorry, can you elaborate? How are lifecycle methods useful for updating the screen when data changes? Component lifecycle methods are componentWillMount, componentDidUnmount etc. But my data may change at any time, and I want to update the screen when my data changes, and I can't wait for the next component lifecycle method invocation.
- TheCoelacanth 10y agoNot sure if I understand what you are asking. It is basically the same as react, you either call setState on the component or pass in different props to the component and then the component gets re-rendered with the new state/props.