1.

What is the lifetime of the data stored through localStorage?(a) Permanent(b) Temporary(c) Both Permanent and Temporary at times(d) Cannot storeI had been asked this question during an interview for a job.The query is from Client-Side Storage topic in division Server-Side and Client-Side Scripting of JavaScript

Answer»

Correct ANSWER is (a) Permanent

Easiest explanation: DATA stored through localStorage is permanent. it does not expire and remains stored on the user’s computer until a web APP deletes it or the user asks the browser (through some browser-specific UI) to DELETE it. This data is stored on the client side server and is USED for faster access of data.



Discussion

No Comment Found

Related InterviewSolutions