I am using browsers localStorage to store a value, but while using google chrome, when we refresh the page using window.location.reload(), lo
localStorage
window.location.reload()
lo
Try it
window.localStorage.setItem("value1", true); var yourvar = window.localStorage.getItem("value1");