Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

react history go back

const history = useHistory()

const goBack = () => {
  history.goBack()
}

return (
  <button type="button" onClick={goBack}>
    Go back
  </button>
);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #react #history
ADD COMMENT
Topic
Name
4+6 =