{"id":49434,"library":"storage-easy","title":"Storage Easy","description":"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.","status":"active","version":"2.0.10","language":"javascript","source_language":"en","source_url":null,"tags":["javascript","storage"],"install":[{"cmd":"npm install storage-easy","lang":"bash","label":"npm"},{"cmd":"yarn add storage-easy","lang":"bash","label":"yarn"},{"cmd":"pnpm add storage-easy","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"Default import only; named destructure fails.","wrong":"const { StoreEasy } = require('storage-easy')","symbol":"StoreEasy","correct":"import StoreEasy from 'storage-easy'"},{"note":"Constructor must be called with 'new'.","wrong":"const easy = StoreEasy('ns', model)","symbol":"new StoreEasy(ns, model)","correct":"const easy = new StoreEasy.Cross('ns', model)"},{"note":"Use get method on proxy, not dot notation directly.","wrong":"easy.proxy.get('person.name')","symbol":"proxy","correct":"easy.proxy.person.name.get()"},{"note":"empty() on easy resets all, empty() on proxy clears proxy model only.","wrong":"easy.proxy.empty()","symbol":"empty","correct":"easy.empty()"}],"quickstart":{"code":"import StoreEasy from 'storage-easy';\nglobal.$model = { count: 0, user: { name: '' } };\nconst easy = new StoreEasy('myApp', global.$model);\neasy.proxy.count = 42;\nconsole.log(easy.proxy.count.get()); // 42\neasy.proxy.increment('count', 10);\nconsole.log(easy.proxy.count.get()); // 52\neasy.proxy.user.set('name', 'Alice');\nconsole.log(easy.proxy.user.name.get()); // 'Alice'\neasy.proxy.delete('count');\nconsole.log(easy.proxy.get()); // { user: { name: 'Alice' } }","lang":"typescript","description":"Initializes Storage Easy with a model, sets and gets values via proxy, increments a counter, and deletes a key."},"warnings":[{"fix":"Define `global.$model` with your initial data structure.","message":"Model must be defined globally as $model before instantiation, otherwise defaults to {}.","severity":"gotcha","affected_versions":">=2.0.0"},{"fix":"Use `StoreEasy.Cross(ns, model)` on both domains.","message":"Cross-domain storage requires both domains to use the same namespace and model.","severity":"gotcha","affected_versions":">=2.0.0"},{"fix":"Call `proxy.get('key')` instead of `proxy.get()['key']`.","message":"proxy.get() returns the entire model object; use proxy.get('key') for nested keys.","severity":"gotcha","affected_versions":">=2.0.0"},{"fix":"Replace `proxy.user.name` with `proxy.user.name.get()` or `proxy.get('user.name')`.","message":"The proxy object does not support direct property reads (e.g., proxy.user.name); use .get() method.","severity":"gotcha","affected_versions":">=2.0.0"},{"fix":"Use `easy.empty()` to reset entire storage; use `proxy.empty()` to clear proxy data only.","message":"empty() on easy resets all namespaces, while empty() on proxy resets only the current proxy's data.","severity":"gotcha","affected_versions":">=2.0.0"}],"env_vars":null,"search_vec":"'api':26 'auto':54 'auto-sync':53 'base':25 'browser':10 'cach':33 'cross':16,44 'cross-domain':15,43 'data':34 'delet':32 'differenti':39 'domain':17,45 'easi':2,5 'includ':40 'increment':30 'isol':42 'javascript':66 'key':38 'lightweight':9 'local':11 'localstorage/sessionstorage':57 'model':36 'month':64 'namespac':41 'packag':62 'provid':21 'proxi':24,51 'proxy-bas':23 'read':28 'releas':58 'share':18 'stabl':61 'storag':1,4,12,46,67 'storage-easi':3 'storeeasy.cross':48 'support':19 'sync':55 'updat':65 'v2.0.10':6 'valid':37 'via':47 'wrapper':13 'write':29","created_at":"2026-06-07T17:01:45.712462+00:00","updated_at":"2026-06-07T17:01:45.712462+00:00","problems":[{"fix":"Use `new StoreEasy(...)` or `new StoreEasy.Cross(...)`.","cause":"Forgetting 'new' keyword when instantiating.","error":"TypeError: StoreEasy is not a constructor"},{"fix":"Ensure the key exists in the model or use optional chaining: `proxy.get('key')`.","cause":"Accessing .get() on a proxy property that doesn't exist.","error":"TypeError: Cannot read properties of undefined (reading 'get')"},{"fix":"Define `global.$model = {...}` before creating a StoreEasy instance.","cause":"Model not defined globally before instantiation.","error":"Uncaught ReferenceError: $model is not defined"},{"fix":"Use `proxy.someKey.set(value)` or `proxy.set('someKey', value)`.","cause":"Calling set directly on proxy instead of a nested property.","error":"TypeError: proxy.set is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":null,"github":null,"docs":null,"changelog":null,"pypi":null,"npm":"storage-easy","openapi_spec":null,"status_page":null,"smithery":null,"categories":["storage"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-07","next_check":"2026-09-05","install_tag":null}}