Subscribe to a leveldb value.
- exposes
put
,batch
anddel
changes through one unified interface - accepts RegExps
- performs an initial
get
for the value (except with RegExp)
const subscribe = require('level-value')
subscribe(db, 'key', value => {
console.log(value)
}).off()
// Alternative EventEmitter API
const sub = subscribe(db, 'key')
sub.on('value', console.log)
sub.off()
$ npm install level-value
MIT