Answers for "how to rerender a component in react on button click"

1

React best way of forcing component to update

this.forceUpdate();
Posted by: Guest on June-11-2020
0

how to rerender a page in React when the user clicks the back button

We had a similar desire and solved it by passing a refresh function from the parent to the child.

for example, when you open the child, you would have something like navigate('Child', { refresh: refreshFunction }

You can then access this function in the child ( via something like this.props.navigation.state.params.refresh(); ) before the back action.
Posted by: Guest on February-24-2020

Code answers related to "how to rerender a component in react on button click"

Code answers related to "Javascript"

Browse Popular Code Answers by Language