Smart Storage
Smart Storage is a TypeScript/JavaScript utility library for validated web storage. It provides a robust and easy-to-use API for managing data in localStorage
, sessionStorage
, and in-memory storage with schema validation. Additionally, a React-specific implementation is available for seamless integration with React applications.
🍟 Features
- Schema Validation: Supports validation using libraries like
zod
andyup
. - Multiple Storage Options: Works with
localStorage
,sessionStorage
, and in-memory storage. - Type Safety: Fully typed API for TypeScript users.
- React Integration: A React-specific library for hooks and context-based storage management.
- Extensibility: Easily extendable for custom storage connectors.
📦 Installation
Core Library
Install the core library for vanilla JavaScript/TypeScript usage:
npm install @themineway/smart-storage-js