AndreBroomes

The method useHistory was recently replaced by useNavigate, they pretty much do the same thing it was just renamed. When you want to utilize useNavigate you have to make sure that you import it.

Once you import it you need to save it to a variable, most preferably called navigate. UseNavigate is commonly used to redirect a user to a new page once they are logged in.

--

--