javascript - Return to previous path using MeteorJS and Iron Routing -


using latest meteor , iron routing, how "go back" previous route? feel silly asking, because seems main feature of iron routing..

for instance, went "/contacts" "/posts" , wanted "go back" app's button (not browser button, though i'd functionality do) /contacts again because last route on. there not one-line command such router.back() put in global routes file whenever triggered?

this seems common question, yet can't find has asked yet.. if so, forgive me , please direct me link.

to go in iron-router, use:

history.go(-1) 

or

history.back() 

both of these supported iron-router.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -