withrouter in React-router v6
const push: NavigateFunction = useNavigate()
Restu Wahyu Saputra
const push: NavigateFunction = useNavigate()