local storage add code example
Example 1: how to add variable to local storage in javascript
localStorage.setItem('key', 'value')
Example 2: set localstorage value
localStorage.setItem("mytime", Date.now());
localStorage.setItem('key', 'value')
localStorage.setItem("mytime", Date.now());