Posts by Denis Macêdo • 11 points
1 post
-
1
votes3
answers1171
viewsA: Error using history.push Reactjs
You can set a function and call it on a button as below onHomePress = () => { const { history } = this.props; history.push("/"); }; render() { const { history } = this.props; return (…
reactanswered Denis Macêdo 11