π· About HTML Web Storage API - 1
A Threadπ§΅ π
π HTML Web Storage API
β HTML web storage is better than cookies.
π What is HTML Web Storage?
β With web storage, web applications can store data locally within the user's browser.
β Before HTML5, application data had to be stored in cookies, included in every server request.
β Web storage is more secure, and large amounts of data can be stored locally, without affecting website performance.
β Unlike cookies, the storage limit is far larger (at least 5MB) and information is never transferred to the server.
β Web storage is per origin (per domain and protocol).
β All pages, from one origin, can store and access the same data.
π HTML Web Storage Objects
β HTML web storage provides two objects for storing data on the client:-
β’ window.localStorage - stores data with no expiration date.
β’ window.sessionStorage - stores data for one session (data is lost when the browser tab is closed).
β Before using web storage, check browser support for localStorage and sessionStorage.
Thanks for reading this thread β€οΈ
If you like it , make sure you:
π· Like the tweet
π· Retweet the first tweet β‘
For more content , follow:
@MrunayU