zapier-async-storage

1.0.0 • Public • Published

zapier-async-storage

Minimalist wrapper for IndexedDB

Usage

npm install zapier-async-storage
import { createInstance } from 'zapier-async-storage';

const db = createInstance({
  storeName: 'my-store',
  dbName: 'AsyncStorage',
  version: 1,
});

db.setItem('hello', 'world')
  .then(db.getItem('hello'))
  .then((result) => {
    console.log(result); // 'world'
  });

Configuration

WIP.

Development

npm run start
open http://localhost:8001/__tests__/

Navigate to http://localhost:8001/__tests__ to view the Mocha test suite.

Browser Compatibilty

This library uses modern JS features like Object.assign and Promise, so for compatibilty with older browsers (i.e., IE), you'll need an appropriate polyfill.

/zapier-async-storage/

    Package Sidebar

    Install

    npm i zapier-async-storage

    Weekly Downloads

    215

    Version

    1.0.0

    License

    UNLICENSED

    Unpacked Size

    41.3 kB

    Total Files

    16

    Last publish

    Collaborators

    • michaelgilley
    • neilff
    • zapier-engineering