Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function test(){
- var myArray = localStorage.getItem('articles') ;
- //myArray=[1,4,5];
- needle = 2 ,
- myArray.push(needle);
- localStorage.setItem('articles', JSON.stringify(myArray))
- console.log(localStorage.getItem('articles'));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement