backendless-where-clause-monitor
v1.3.3
Published
Backendless Where Clause Monitor
Downloads
10
Readme
"dependencies": {
...
"backendless-where-clause-monitor": "git+ssh://[email protected]:backendless/where-clause-monitor.git"
...
}
import createWhereClauseMonitor from 'backendless-where-clause-monitor'
const createWhereClauseMonitor = require('backendless-where-clause-monitor')
const whereClause = "foo = 'bar' and age > 25 "
const whereClauseMonitor = createWhereClauseMonitor(whereClause)
whereClauseMonitor({ foo: 'bar', age: 123 }) => true
whereClauseMonitor({ foo: 'bar', age: 123, bar: 'string' }) => true
whereClauseMonitor({ foo: 'bar' }) => false
whereClauseMonitor({ age: 123 }) => false
whereClauseMonitor({ foo: 'bar2', age: 123 }) => false
whereClauseMonitor({ foo: 'bar', age: 10 }) => false
npm test