immediate-chunk-store

WebJar for immediate-chunk-store

Лицензия

Лицензия

MIT
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

immediate-chunk-store
Последняя версия

Последняя версия

2.0.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

immediate-chunk-store
WebJar for immediate-chunk-store
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/feross/immediate-chunk-store

Скачать immediate-chunk-store

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/immediate-chunk-store/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>immediate-chunk-store</artifactId>
    <version>2.0.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/immediate-chunk-store/
implementation 'org.webjars.npm:immediate-chunk-store:2.0.0'
// https://jarcasting.com/artifacts/org.webjars.npm/immediate-chunk-store/
implementation ("org.webjars.npm:immediate-chunk-store:2.0.0")
'org.webjars.npm:immediate-chunk-store:jar:2.0.0'
<dependency org="org.webjars.npm" name="immediate-chunk-store" rev="2.0.0">
  <artifact name="immediate-chunk-store" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='immediate-chunk-store', version='2.0.0')
)
libraryDependencies += "org.webjars.npm" % "immediate-chunk-store" % "2.0.0"
[org.webjars.npm/immediate-chunk-store "2.0.0"]

Зависимости

Библиотека не имеет зависимостей. Это самодостаточное приложение, которое не зависит ни от каких других библиотек.

Модули Проекта

Данный проект не имеет модулей.

immediate-chunk-store travis npm downloads javascript style guide

Immediate put/get for abstract-chunk-store compliant stores

abstract chunk store

Makes store.put() chunks immediately available for store.get(), even before the store.put() callback is called. Data is stored in memory until the store.put() is complete.

Install

npm install immediate-chunk-store

Usage

var ImmediateChunkStore = require('immediate-chunk-store')
var FSChunkStore = require('fs-chunk-store') // any chunk store will work

var store = new ImmediateChunkStore(new FSChunkStore(10))

store.put(0, Buffer.from('abc'), function () { /* yolo */ })

// And now, get the same chunk out BEFORE the put is complete
store.get(0, function (err, data) {
  if (err) throw err
  console.log(data.toString()) // 'abc'
})

License

MIT. Copyright (c) Feross Aboukhadijeh.

Версии библиотеки

Версия
2.0.0