Wondering what’s next for npm?Check out our public roadmap! »

    deep-storage-adapter
    TypeScript icon, indicating that this package has built-in type declarations

    0.1.0 • Public • Published

    deep-storage-adapter

    Turns a flat key-value store into a pseudo-document store.

    Node.js CI

    Note that this package is in early stages of development and there may be breaking changes within semantically compatible versions. See change log.

    Installation

    yarn add deep-storage-adapter
    

    Usage

    let deepStore = new DeepStorageAdapter({
        store: sessionStorage,
        encoder: require("base62/lib/ascii"), // See https://github.com/base62/base62.js
    });
    
    deepStore.setItem('item', {
        foo: 'bar',
        type: 2
    });
    
    let item = deepStore.getItem('item');
    // item matches original object

    Install

    npm i deep-storage-adapter

    DownloadsWeekly Downloads

    22

    Version

    0.1.0

    License

    MIT

    Unpacked Size

    31.3 kB

    Total Files

    9

    Last publish

    Collaborators

    • avatar