cache-storage-chunk-store
![license](https://img.shields.io/:license-MIT-blue.svg)
![abstract chunk store](https://cdn.rawgit.com/mafintosh/abstract-chunk-store/master/badge.svg)
Install
npm install cache-storage-chunk-store
or include it directly:
<script src="https://cdn.jsdelivr.net/npm/cache-storage-chunk-store@1.x/dist/cache-storage-chunk-store.min.js"></script>
Usage
const CacheStorageChunkStore = require('cache-storage-chunk-store')
const chunks = new CacheStorageChunkStore(10)
chunks.put(0, buffer, (err) => console.error(err))
chunks.get(0, (err, buf) => console.log(err, buf))
Known issues
Chrome can stall and never finish if running many get
calls concurrently.
Specifically this problem occurs when calling the ReadableStream.getReader.read()
function more than once.
License
MIT