Answers for "check if there are elements in localstorage"

1

check if item exists in localstorage javascript

//If the given key does not exist in the list associated with the object then this method must return null.

if (localStorage.getItem("infiniteScrollEnabled") === null) {
  //...
}
Posted by: Guest on June-03-2021

Code answers related to "check if there are elements in localstorage"

Code answers related to "Javascript"

Browse Popular Code Answers by Language