local-storage-fallback

JSON →
library 5.0.0 ·javascript
verified Jun 7, 2026

A browser storage adapter that automatically falls back through localStorage, sessionStorage, cookies, and in-memory storage, depending on what is available and not throwing exceptions (e.g., in private browsing mode). Current stable version is 5.0.0. Maintained infrequently. Key differentiator: handles private browsing and quota errors gracefully where native localStorage would throw, and provides a unified API across all backends. Fully typed with TypeScript definitions.