Answers for "how to store and get a single variable in local storage js"

0

how to store and get a single variable in local storage js

var userName = "SHAM3R";
//store
localStorage.setItem("storeUserName", userName);
//get
let getUserName = localStorage.getItem("storeUserName");
Posted by: Guest on October-09-2021

Code answers related to "how to store and get a single variable in local storage js"

Code answers related to "Javascript"

Browse Popular Code Answers by Language