npm.io
1.2.7 • Published yesterday

@anchorlib/storage

Licence
MIT
Version
1.2.7
Deps
0
Size
97 kB
Vulns
0
Weekly
79
Stars
27

@anchorlib/storage

A comprehensive storage solution for modern web applications with support for multiple storage backends including IndexedDB, Session Storage, and Memory Storage.

Features

  • Multi-backend Support: Works with IndexedDB, Session Storage, and in-memory storage
  • Reactive Storage: Automatic synchronization with browser storage mechanisms
  • Promise-first API: IndexedDB operations with modern Promise-based interface
  • Real-time Updates: Subscribe to storage changes with event system
  • TypeScript Support: Full TypeScript support with comprehensive type definitions
  • Schema Validation: Integration with @anchorlib/core for reactive state management

Installation

npm install @anchorlib/storage

Documentation

For full documentation, visit Anchor Storage Documentation

Quick Start

import { MemoryStorage } from '@anchorlib/storage';

const storage = new MemoryStorage();
storage.set('key', 'value');
console.log(storage.get('key')); // 'value'

License

MIT


## License

MIT

Keywords