storage-easy v2.0.10 is a lightweight browser local storage wrapper with cross-domain sharing support. It provides a proxy-based API for reading, writing, incrementing, and deleting cache data with model validation. Key differentiators include namespace isolation, cross-domain Storage via StoreEasy.Cross, and a proxy that auto-syncs with localStorage/sessionStorage. Released as a stable package with monthly updates.
npm install storage-easyNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Initializes Storage Easy with a model, sets and gets values via proxy, increments a counter, and deletes a key.
Define `global.$model` with your initial data structure.
Use `StoreEasy.Cross(ns, model)` on both domains.
Call `proxy.get('key')` instead of `proxy.get()['key']`.Replace `proxy.user.name` with `proxy.user.name.get()` or `proxy.get('user.name')`.Use `easy.empty()` to reset entire storage; use `proxy.empty()` to clear proxy data only.
Use `new StoreEasy(...)` or `new StoreEasy.Cross(...)`.
Ensure the key exists in the model or use optional chaining: `proxy.get('key')`.Define `global.$model = {...}` before creating a StoreEasy instance.Use `proxy.someKey.set(value)` or `proxy.set('someKey', value)`.No dependency data recorded yet.