3 ms·
I’m a little confused by this and maybe I’m missing something. Wasn’t localStorage always intended to be treated as a volatile storage mechanism for non-critica
by finaliteration 7y ago
I’m a little confused by this and maybe I’m missing something. Wasn’t localStorage always intended to be treated as a volatile storage mechanism for non-critical data and caching? The advice I’ve seen for several years says to avoid storing sensitive or critical data there.
Can PWAs not switch to using IndexedDB which seems like it’s more purpose-built for this use case?
No snark intended. I’m legitimately curious what the situation is and where any blockers are.
- nicoburns 7y ago> Can PWAs not switch to using IndexedDB which seems like it’s more purpose-built for this use case? IndexedDB is also subject to the 7 day limit. Leaving no persistent storage for web apps at all.
- finaliteration 7y agoAh, I missed that in the original documentation and most of the discussion I've seen has been around localStorage. Thank you!
- capableweb 7y agoIt's a bit confusing because there are two similar terms being used to describe this. First is "local storage" which refers to any of the storage, as long as it's on the local device. Second (which you used) is "localStorage", which refers to specifically the window.localStorage API (which you are right about, has been described as a volatile short-term memory for apps).
- judah 7y agoIn the original post from Apple[0] announcing these measures, they've listed all script-writable locations are subject to cache clearing: - Indexed DB - LocalStorage - Media keys - SessionStorage - Service Worker registrations (I guess this means service worker caches) [0]: https://webkit.org/blog/10218/full-third-party-cookie-blocking-and-more/ https://webkit.org/blog/10218/full-third-party-cookie-blocki...
- finaliteration 7y agoThank you for outlining that! I missed the impact on Indexed DB in my original read of the issue. It makes more sense, now.