Augmented.js presentation storage module providing LocalStorage and NamespacedLocalStorage for client-side data persistence. Version 2.5.7 offers a factory pattern (LocalStorageFactory) to create storage instances with optional namespacing. It wraps native localStorage with a simple API (getItem, setItem, removeItem, clear, key, length) and browser support detection. Unlike raw localStorage, it provides namespaced storage to avoid key collisions. Release cadence is low, tied to the Augmented.js project. The library is lightweight with minimal dependencies.
npm install presentation-storageNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to create both persistent and non-persistent, namespaced storage instances, set/get/remove items, and use getNamespacedItems.
When using namespace, use getNamespacedItems() to retrieve all items within the namespace; clear() only clears within the namespace.
Ignore the persist parameter or set it to true for consistency.
Only use clear() on namespaced instances or be aware of destructive behavior.
Check the return value before calling methods: const storage = LocalStorageFactory.getStorage(true); if (storage) { ... }Use named imports: import { LocalStorageFactory } from 'presentation-storage'; then call factory method.No dependency data recorded yet.