0.8.0 • Published 5 years ago

rethinkdb-store v0.8.0

Weekly downloads
4
License
ISC
Repository
github
Last release
5 years ago

rethinkdb-store

A high level nodejs library for accessing rethinkdb data.

Install

$ npm install rethinkdb-store

Usage

const store = require('rethinkdb-store');

//Or config througth environment vars `RTK_HOST`, `RTK_PORT`, `RTK_DB`
store.setConfig({
  host: 'localhost',
  port: 28015,
  db: 'test'
})

Writing data

store.insert({host, port, db, table, docs}) -> object
store.upsert({host, port, db, table, docs, resolver}) -> object
store.delete({host, port, db, table, id}) -> object

Selecting data

store.getById({host, port, db, table, id, fields}) -> object
store.getAll({host, port, db, table, fields}) -> object
store.getByIndex({host, port, db, table, index, value, page, size, fields}) -> object
store.sampleByIndex({host, port, db, table, index, value, sample, fields}) -> object
store.getByIndex({host, port, db, table, index, value, page, size, fields}) -> object
store.betweenByIndex({host, port, db, table, index, from, to, page, size, fields}) -> object
0.8.0

5 years ago

0.7.1

5 years ago

0.7.0

5 years ago

0.6.0

6 years ago

0.5.0

6 years ago

0.4.0

6 years ago

0.3.0

6 years ago

0.2.0

6 years ago

0.1.0

6 years ago