Local Storage API

Overview

Local Storage API is a part of Web Storage API which allows web apps to store data locally as key/value pairs within the browser's storage.

The data stored using Local Storage API is persistent - ie, the stored data for the same origin is accessible across multiple tabs and sessions, and it does not get cleared from the storage even if the tab or browser is closed.

Demo

https://nectar.website/demo/web-apis/local-storage/

Usage

You can refer to the code present in /partials/web-apis/local-storage.html file and use it accordingly.

Reference

https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage

Last updated