1.

How do you add a particular state to the browsing history?(a) pushState()(b) replaceState()(c) state()(d) addstate()The question was posed to me by my school teacher while I was bunking the class.My question comes from History Management in JavaScript topic in portion Sockets of JavaScript

Answer»

The correct OPTION is (a) PUSHSTATE()

Explanation: The pushState() method adds a particular state to the browsing history. It pushes the GIVEN data onto the session history stack with the specified TITLE and, if provided, URL.



Discussion

No Comment Found

Related InterviewSolutions