promiredis
v0.1.1
Published
Promise wrapped node redis client
Downloads
3
Readme
Promiredis
Promise wrapped node redis client.
Installation
npm i --save promiredis
Usage
import promiredis from 'promiredis'
async function main() {
promiredis.initialize({ port: 6379, host: 'localhost', namespace: 'FOO' })
// will write into key 'FOO/foo'
await promiredis.set('foo', { name: 'foo' })
// will get from key 'FOO/foo'
const res = await promiredis.get('foo')
}
try {
main()
} catch (e) { ... }