The window.history
object contains the browsers history.
Window History
The window.history
object can be written without the window prefix.
To protect the privacy of the users, there are limitations to how JavaScript can access this object.
Some methods:
history.back()
– same as clicking back in the browserhistory.forward()
– same as clicking forward in the browser