# keev

> Minimalist Key/Value store with a streaming api.

Latest version **0.4.0** (published 2015-03-15) · ISC license · 0 weekly downloads

## Install

```sh
npm install keev
pnpm add keev
yarn add keev
bun add keev
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.4.0 |
| Published | 2015-03-15 |
| First published | 2015-03-13 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | allain |
| Maintainers | allain |
| Keywords | key value, store |

## Links

- npm: https://www.npmjs.com/package/keev
- Repository: https://github.com/allain/keev
- Issues: https://github.com/allain/keev/issues
- npm.io page: https://npm.io/package/keev

## Recent versions

- 0.4.0 (latest) — 2015-03-15
- 0.3.0 — 2015-03-15
- 0.2.0 — 2015-03-13
- 0.1.2 — 2015-03-13
- 0.1.1 — 2015-03-13
- 0.1.0 — 2015-03-13

## README

# keev

Minimalist Key Value store with a Streaming api.

[![build status](https://secure.travis-ci.org/allain/keev.png)](http://travis-ci.org/allain/keev)

## Installation

This module is installed via npm:

``` bash
$ npm install keev
```

## Example Usage

``` js
var stdout = require('stdout');

var db = require('keev')();

var dbStream = db.createStream();

dbStream.pipe(stdout()); // Just spit it to the console

dbStream.write({ a: 10 }); // Store a=10
dbStream.write({ a: null }); // Query for the value of a
dbStream.write({ a: "foo" }); // Store a="foo"
dbStream.write({ a: undefined }); // Delete a from store
dbStream.write({ a: null }); // Succeeds in not returning the key a
```

## API

```var db = require('keev')({options});```

`options.store` is a an object with the following methods. If a store it not given, it will assume a memory store.

A store must implement:

`getAll(keys, cb)`
> where cb is a callback that with the signature `function(err, obj)`.
> For each key passed in the object will have a property, if a value is not found, it's value will be undefined.

`putAll(obj, cb)`
> where cb is a callback that with the signature `function(err)`.
> For each key in the object, the store should delete the key if the value given is undefined, or set it otherwise.

```Keev.createStream()```
Returns a stream which when written to supports querying, deleting, and putting.

```Keev.createQueryStream()```
Returns a stream which only queries for values where the value of properties is null, passing all others through without change.

```Keev.createChangeStream()```
Returns a stream which applies all changes, but passing through any properties with null values unchanged.

---
_Source: https://npm.io/package/keev · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
