js .setItem code example
Example 1: set localstorage
function set(){
var sendJson = JSON.stringify(arrayName);
localStorage.setItem('key',sendJson)
}
Example 2: setlocalstorage
localStorage.setItem('data', JSON.stringify(arryName));
function set(){
var sendJson = JSON.stringify(arrayName);
localStorage.setItem('key',sendJson)
}
localStorage.setItem('data', JSON.stringify(arryName));