idb-lucass
v1.2.2
Published
A content addressable file store on top of indexedDB, implemented to the [`lucass`](https://github.com/mikeal/lucass) spec.
Downloads
5
Readme
idb-lucass
A content addressable file store on top of indexedDB, implemented to the
lucass
spec.
API conforms to the lucass spec and supports optional arguments to the hasher.
const idblucass = require('idb-lucass')
const store = idblucass('noop', argHasher)
store.set(Buffer.from('asdf'), (err, hash) => {
if (err) throw err
store.get(hash, (err, buff) => {
if (err) throw err
console.log(buff.toString()) // 'asdf'
})
})