#Going back to previous route

4 messages · Page 1 of 1 (latest)

finite sable
#

Hey guys, I have a question.
Is it possible with the tanstack router to go back to the previous visited route? something like

const nav = useNavigate()
nav({ to: -1 })

zealous turret
#

@finite sable You can try something like

let router = useRouter();
router.history.back();
glossy turret
#

Yes, this the recommended way.

serene rivet