{"name":"waterline-criteria","version":"1.0.1","description":"Utility library for use in Sails adapters where you need to filter a list of output using a criteria object","main":"index.js","scripts":{"test":"mocha test --recursive","prepublish":"npm prune"},"repository":{"type":"git","url":"git+ssh://git@github.com/balderdashy/waterline-criteria.git"},"keywords":["waterline","utility"],"author":{"name":"Mike McNeil"},"license":"MIT","dependencies":{"lodash":"3.10.1"},"testDependencies":{"mocha":"~1.12.0","bower":"~0.10.0","grunt":"~0.4.1","grunt-text-replace":"~0.3.6","grunt-contrib-clean":"~0.5.0","grunt-contrib-uglify":"~0.2.2"},"devDependencies":{"mocha":"^2.0.1"},"gitHead":"aebef48abd3c2dd5af263085513070a3f1103fa3","bugs":{"url":"https://github.com/balderdashy/waterline-criteria/issues"},"homepage":"https://github.com/balderdashy/waterline-criteria#readme","_id":"waterline-criteria@1.0.1","_shasum":"8877057ec7d6472100017a3a57fcc94b62a1fda9","_from":".","_npmVersion":"2.15.2","_nodeVersion":"4.2.2","_npmUser":{"name":"particlebanana","email":"particlebanana@gmail.com"},"dist":{"shasum":"8877057ec7d6472100017a3a57fcc94b62a1fda9","tarball":"http://registry-npm.ywwl.com/waterline-criteria/download/waterline-criteria-1.0.1.tgz","integrity":"sha512-95v6fCeKyf7zJ7H0+CH4us8sB1RVkOYsnKoyt+bc//YtmpAeDEIl0dqIWJteOQuYfl2ZpXUf8goM9psoVdZ/5g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHqkJYqfu8V9hqWQrwUc3N7BaD7llU5mIfgZeQyIV3NAAiEAwJuOQ547GizD5lKra5yQ1ZiLTY1++cOC5tYUk+Omrck="}],"size":8813,"noattachment":false,"key":"/waterline-criteria/-/waterline-criteria-1.0.1.tgz"},"maintainers":[{"name":"balderdashy","email":"mike@balderdash.co"},{"name":"mikermcneil","email":"michael.r.mcneil@gmail.com"},{"name":"particlebanana","email":"particlebanana@gmail.com"},{"name":"sgress454","email":"sgress454@treeline.io"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/waterline-criteria-1.0.1.tgz_1465253536509_0.09858566778711975"},"directories":{},"readme":"# waterline-criteria\n\nUtilities for working with Waterline criterias, especially for applying them to in-memory datasets.\n\n> This module was designed for adapters which communicate with key/value stores such as [`sails-disk`](https://github.com/balderdashy/sails-disk), [sails-memory](https://github.com/balderdashy/sails-memory), and [sails-redis](https://github.com/balderdashy/sails-redis) (i.e. they already implement the `semantic` interface, but need to implement the `queryable` interface).\n\n\n## Installation\n\n```sh\n$ npm install waterline-criteria --save\n```\n\n## Usage\n\n```js\nvar wlFilter = require('waterline-criteria');\n\nvar SOME_DATASET = [\n  {\n    id: 1,\n    name: 'Lyra'\n  },\n  {\n    id: 2,\n    name 'larry'\n  }\n];\n\nvar results = wlFilter(SOME_DATASET, {\n  where: {\n    name: { contains: 'lyr' }\n  }\n}).results;\n\n// x ==> [{name: 'Lyra', id: 1}]\n```\n\n## Bugs &nbsp; [![NPM version](https://badge.fury.io/js/waterline-criteria.svg)](http://npmjs.com/package/waterline-criteria)\n\nTo report a bug, [click here](http://sailsjs.com/bugs).\n\n> This is a built-in module in the Sails framework and the `sails-disk` adapter.  It is installed automatically when you run `npm install sails`.\n\n#### Version notes\n\nThe master branch of this repository holds `waterline-criteria` used in Sails versions 0.10.0 and up.  If you're looking for the version for the v0.9.x releases of Sails, the source is [located here](https://github.com/balderdashy/waterline-criteria/releases/tag/v0.9.7).\n\n## Contributing &nbsp; [![Build Status](https://travis-ci.org/balderdashy/waterline-criteria.svg?branch=master)](https://travis-ci.org/balderdashy/waterline-criteria)\n\nPlease observe the guidelines and conventions laid out in the [Sails project contribution guide](http://sailsjs.com/contribute) when opening issues or submitting pull requests.\n\n[![NPM package info](https://nodei.co/npm/waterline-criteria.png?downloads=true)](http://npmjs.com/package/waterline-criteria)\n\n## License\n\nThe [Sails framework](http://sailsjs.com) is free and open-source under the [MIT License](http://sailsjs.com/license).\n","publish_time":1465253538933,"_cnpm_publish_time":1465253538933,"dist-tags":{"latest":"2.0.0"}}