{"_id":"schm-mongo","_rev":"12-8997c48041b5af05a10b166186b489c9","name":"schm-mongo","dist-tags":{"latest":"0.4.1"},"versions":{"0.1.0":{"name":"schm-mongo","version":"0.1.0","description":"Composable, immutable, parseable and validatable (yeah, many *ables) schemas for Node/JavaScript","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","postinstall":"npm run build","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^6.0.0","eslint":"^4.18.2","flow-bin":"^0.66.0","jest-cli":"^22.4.2","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.5"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.1.0","dist":{"shasum":"4640daac0c3a1aaade443cecc6ed9e1835b9fa44","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.1.0.tgz","fileCount":14,"unpackedSize":26624,"integrity":"sha512-RLpqJLo9it3yJw6Xt2UVatuqfS81KJBXt8BDmvpKebe4SFVKczkcou9r0f5l44ACz+YwHF4ZJ8DxYzyhtx0hZw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCU/qO8GQ/HaRA85m7J7UR0Ma30uGXY0mbUySuhYSfLnAIhALwPcqWQHbFc/Y1XweWpBFdzdIgZTp0ddGrWCZxVSHhr"}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.1.0_1520704077936_0.921215598702694"},"_hasShrinkwrap":false},"0.1.1":{"name":"schm-mongo","version":"0.1.1","description":"Composable, immutable, parseable and validatable (yeah, many *ables) schemas for Node/JavaScript","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","postinstall":"npm run build","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^6.0.0","eslint":"^4.18.2","flow-bin":"^0.66.0","jest-cli":"^22.4.2","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.6"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.1.1","dist":{"shasum":"f2ef30cba14476b9f7feed0e6ef3250af578867f","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.1.1.tgz","fileCount":14,"unpackedSize":26624,"integrity":"sha512-pKrUTTmxXALwdKNMIpGYdAltnNazv0Af3NW8YWs3SWOhqa1zXRsx6xpzfhbcUXDZs/BXPIx9qe81fogNGvsaKw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFoFco7bHmzB59dcCGf9903LPz8Yp4hu6MXuSPN2+ujZAiAe9tEJwAnYim64Yu9FmrF2J2C1v5fz1rtAH/uYdYBDqQ=="}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.1.1_1520809315311_0.8061233051077683"},"_hasShrinkwrap":false},"0.1.2":{"name":"schm-mongo","version":"0.1.2","description":"Composable, immutable, parseable and validatable (yeah, many *ables) schemas for Node/JavaScript","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^6.0.0","eslint":"^4.18.2","flow-bin":"^0.66.0","jest-cli":"^22.4.2","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.7"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.1.2","dist":{"shasum":"0429c386e6c248006635da1f6520a4b8e97c5fc2","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.1.2.tgz","fileCount":14,"unpackedSize":26588,"integrity":"sha512-2KfBfkuqrcD1lHMEWGO6Rgathsk8lujEZURk4ExZ4JPMNUbe4AGSUN1WD4iWbepJ7Rh8qbHPLR2Mwp6m0/wJIw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD4mmKVMB7LzkolIxvMOeK4k3Aq4eV7Eh+S5dAJ6w6UuQIgUHxchMEIyDHcnPqK2mDVU2hM1w6vixjzIL/IKAbFdys="}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.1.2_1521724125878_0.33061546882765636"},"_hasShrinkwrap":false},"0.2.0":{"name":"schm-mongo","version":"0.2.0","description":"Composable, immutable, parseable and validatable (yeah, many *ables) schemas for Node/JavaScript","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^6.0.0","eslint":"^4.18.2","flow-bin":"^0.66.0","jest-cli":"^22.4.2","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.7"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.2.0","dist":{"shasum":"12b21e474ba57281e4a2abbe6089e0bc1f5f9d89","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.2.0.tgz","fileCount":13,"unpackedSize":24596,"integrity":"sha512-HCTwztu+k2C6L+4TEm0dYkXb/6YprnxV/Dv2fmTerMAMizzZodRJ7aONnvIMrUwN9vVY4us3Bdb5BG/6AOvPcg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCl4cMONdU0O1pk2Hg0X4TzTlTpmozz46Cw+a3zs6mSwwIhALMjc2tdZKBLlglC0SFM+HYI1tvH+osUX2BoWuPy4285"}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.2.0_1521825027463_0.08359297245398523"},"_hasShrinkwrap":false},"0.2.1":{"name":"schm-mongo","version":"0.2.1","description":"Extend schm schemas so as to work with MongoDB","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^8.0.0","eslint":"^4.18.2","flow-bin":"^0.74.0","jest-cli":"^23.1.0","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.8"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.2.1","dist":{"shasum":"06eaa74961353898e35e775ebf9ef8183149d1b1","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.2.1.tgz","fileCount":13,"unpackedSize":24748,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH1ZlCRA9TVsSAnZWagAA3qAP/1uUtGE7BgbYE6+mvKXS\nZPZ24+a9t2bNJkkz0wnnlUGEpqRU86MVhGTiliDXYABf4LWqEAJlZFPsrdD2\nXzyO1o971b9Rzb4xxrkRf0dh5+/ae439Tl/louHhHPzwsWFtsh5IbDpP+EP9\nrLx7Y1DGwdWj8kpDgfvZtVS0RxLrqjAxv4hRk8A3P1ULdrwWB6+XCq5agSvs\noYu/ckfR1UHCQdkCSIajwqQLLGkLKk8ltAEH+eG0GziSW0QuKLZXPyNOLRFZ\n/FG7yFM93IBcrUs566Tb6sO25aw4SbdGnkl1ErCaoW4htHwo3+r5t4jyb5S5\nPErfT12qjyUclteNK2osdLFz/q4hrNY7mBNtKbJG2kzzo68kP3zreKaRaeXN\nocxQkXhdiVjDNFUIElQD0Dp+gJYMrrXUO7Ey5TLGQUEG0S0f2fDHVmWqutXI\noC+2w6nP/ltLC9irGTNuixWVIcbXdXMrXyF5A753kvaxTbZdBrsV/YIenFBA\n1By3wqNQKVk6xYTcibyXpm7WDAF+yW+oYoa7VbnfHuLAZ0G3+2xcuIEIZZte\nVrKBY3RC6lvJMCPCjvNI0+Oso0YvbP015NmQKvZZeLxqGlOos7TuNOeJjNhz\n7yA3+piBepO5n6krIoJwtiSCsWt8Q0i0G7KR67mbcPwa5gc+lhCOaqn29mY8\nrY/Z\r\n=6L2a\r\n-----END PGP SIGNATURE-----\r\n","integrity":"sha512-M7ykSdyuNvdd31udspUhDT7I5csBiIM5NLgq0mMMN28twgc8lIGW5vunlaGWfnJR7i39V9FD6Tj0lIFyfYQSMw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCFj6G4jhlg8GQM5vssoncycvxXFfLhSDhv7QMDprzL5gIgUYf5P7Y8UQe7XZ3Pp+sydCgVLTeH1KcASd9G3Gyq5iU="}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.2.1_1528780388900_0.27010331383621367"},"_hasShrinkwrap":false},"0.2.2":{"name":"schm-mongo","version":"0.2.2","description":"Extend schm schemas so as to work with MongoDB","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^8.0.0","eslint":"^4.18.2","flow-bin":"^0.74.0","jest-cli":"^23.1.0","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.9"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.2.2","dist":{"shasum":"ed60963d2d0228659f5e275b87f969a851f7a614","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.2.2.tgz","fileCount":13,"unpackedSize":24748,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH1b0CRA9TVsSAnZWagAA8qcP/RnpGUlL/XjJvA9gGLgx\nvtwhQB1kJBGMt+edGRcHgILfTZFyAiYkI/CrAweB1x9ILisDBTTmHwY95E21\ncegbkB+ELXltIzYk2niL62rfxw2xxRg57Gs6I0ofZCuYnQov1ymuYxGhSHMK\n6TCYzRl5CEor5O0cidZUAQ9lFjjsAVzGwJ9WK7aze5d/9jTWVzJb2nhECQZa\nQpA70TTwLbD02vWC5orINN77/6MQaAIaDoTohb3Jghaj1vxK/g5R1Ei+XgAx\nWMcgI+2UaXAsijkVTyKX7ZwPgMpiz17kdXi+0N6BIq+0DetI2qdh2sl8LA1l\n6XM+57nVVyFekk6bKzvSSg1kx8jl/0tcS/PzeCV6m1HlH24y0PCZazCSBQ+1\nRynGZYJteGA0KOwv9C3vFeOYFo7l4+Wq32szQ9niwyik1eIXia0ISqMYX+Wf\nisFn+62mm58ufB1GToyG+BKEfVmooOmz22EjUs3ayroXoEDojaj7waUsK09d\n0Pa9FtX7VuezxSamImdhg4naE50vgZd0q03TD8ETqgUG4GyVu2arxEJUR//G\nOSOdZoXeM8Xn2Z4hUnEj7ENm0SOF8lMXRCWW+B/9w1iWIDf4csYTjAyvbTfn\nbUQT9cStHj+Gwq+PEk6ShNWcs1TDpLiaqZckzM6D3GSPycAEd2lobSn9fL0e\n+z2U\r\n=ugy2\r\n-----END PGP SIGNATURE-----\r\n","integrity":"sha512-pH9CWtzfblXa0VlWRL+unLbuI8qQ3t0UCHjTcubcCd7UUdfujK7u8oZrsrGR2602q8hTUStqpNY2ua7XnhR9tQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCBIuxxlkBRf2orx6jLP1nBe0uvG3InBJDEEGoYC4kZkgIgJ/ab760EafzsQn7hW59byN0ZF0b23JBjDKs8MefiFF8="}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.2.2_1528780532076_0.5644711308435102"},"_hasShrinkwrap":false},"0.2.3":{"name":"schm-mongo","version":"0.2.3","description":"Extend schm schemas so as to work with MongoDB","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^8.0.0","eslint":"^4.18.2","flow-bin":"^0.74.0","jest-cli":"^23.1.0","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.3.10"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.2.3","dist":{"shasum":"ff06b52f1e78b4ccd66a01f398f8e16661471da3","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.2.3.tgz","fileCount":13,"unpackedSize":24749,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH1jFCRA9TVsSAnZWagAAHc8P/3mlNojUmD5jTH9byxoG\nT39usdJtnLI+wZLy7F7cLcI2Yfqkx1lN1Y/rfid8bpxC2pSc4pAPpIQY/d7u\n1dwGbmLcsioDoA4m8dw+3amUiMSe7B5i71MkNhlVVHVXbSOViBvz86IBGMLM\nXnr6saWPOdRIE/Q0jD/CINkPs8Q5Hcveq1tz4jgpK0TRwOXVmdxLWWHZ+qD0\nNLPy9oKZAHAPM4sQ/ZFziQjji2fn2nW5NniMu/OTxfGcd4gHILcyWHriISc8\n+xbNEQNl4IWBrSLzIR0HAtL1rxY0IXErtsGT2rUOXFPKsEAtR5+rvIdJ6XyO\n/C3C4o5IWKPTN9VKIkBkmbROtBAIYT2VbB7Yyr5d8NEBpOZ0pYy7TSo6vW35\nxA3U9GJu33Q1Ezw4WNttCQeQVsrFj1yMPUUnEeRy8LdEI99yn6VbHPo36gAq\ns2Y7FDwFDkzjoS0gjLqomItt8GMASVRpSequDN3Iipb5/9LADq8W2CSDwo8k\nUX7HR5RC0rhy0MYoex8INTqpVixT691YfAYeO7bBAHMiRhcGH1Xf/2/UVttm\nHMIzaNBuMWaUoVcq5p4j3gofTv0DK9AohETipoqDJ2ppJf/yRiqbreyvOIfP\nhM6uMCEr8jJGO4jIkwpnjZzjGL2YaTMfXFKqNGyoVBwYlTL8MHTfZpkCNvIm\npRdv\r\n=Fz4X\r\n-----END PGP SIGNATURE-----\r\n","integrity":"sha512-XWZRd6B/QIW4V0eA0zAGIjYi9ssfqnhlz4kEZjPPt2T9am5uuh42uIuQZHq+K3PpAgH1FuoBTlIyA6SBFzk3bA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICw+e1HfhviREHVt5T4LO1Lu7R+MbdfYjTr16m4lrD3vAiAz3ewg6ZwtzkTG/YulIKlMCvrsX1VQ4zB/E/risfq0OQ=="}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.2.3_1528780996349_0.19293889969686018"},"_hasShrinkwrap":false},"0.3.0":{"name":"schm-mongo","version":"0.3.0","description":"Extend schm schemas so as to work with MongoDB","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"files":["dist"],"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","prepublishOnly":"npm run lint && npm test && npm run build"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"babel-cli":"^6.18.0","documentation":"^8.0.0","eslint":"^4.18.2","flow-bin":"^0.74.0","jest-cli":"^23.1.0","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.4.0"},"peerDependencies":{"schm":"^0.3.4"},"_id":"schm-mongo@0.3.0","dist":{"shasum":"2d7ebd425f7e16ad736eed1cedc0e77cbc6015b3","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.3.0.tgz","fileCount":13,"unpackedSize":24748,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbH1lUCRA9TVsSAnZWagAAFBQP/jbeSyaXKrYWfTzDB97W\nbGfsvAMVWPjcljsS3xwYlpL3ahMG8Dn4x1XS9HiKKe1kZUnP7eMQf5FN5FId\nqhkw5vt3BoivViDK+2V/ZzLOGWv8ondzSbdZe4mLJm1W2h3EoT9M+vl6cqD6\nYa7OPDw1msbnln654iKUX4NI3Gjb9jhcpJHGxxEOdpEPnA2HaSY1KCfqMk4V\n6DlOCorqpaRiVpquJEWh37gzM1a7uhJIejBkude6rTO6vio88Gf9WGCCADDa\n55q8wGq/ZQTf2RVCCkzhP8rucDxgfV5lsDndmme3srz10p9h+fFmQBNJymnb\nxFUw38C2KIvDMgIYTErRuLSJfmjX6mevZ1AxvwtHrU5IUUGoexeofaKWZeN+\nDP2drx+NSdL7G+ILboovZKul7J6I7TrPtAdXhS8YWIm1kM7CGoeqooz1EazM\nqK5oKvEFv33MwFIZo7hw0bXaIs3fBTkT/PbtanjXpaE0sjWGODUjRR4udpNu\nvrU8ffBGak9rGfIrpkYgooOGkxhTEcqpl44zviulg6UxhRrFc/87enM5phCS\nOMghFzg6Iwr+CGwlpBjFI4QPvTFx/Unv7XKxCXOWHJxjRpWbow3eZtK1jMEZ\nr1lhSCqhqihwajaP0FNssfk47Aer4/nTsUjSiwz0vmvslXdfZs5Sjl7VxWJm\neeFN\r\n=0IGx\r\n-----END PGP SIGNATURE-----\r\n","integrity":"sha512-i9/AdXP+LEexOnJ6NPRLh7tQ18KNAlw0hZ04PDc+fDBDE9XIDyMNc68zs/u89NB1LpCYRxeBA8G56k4FAEqnjQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDiYrpWek6GRfb9PdR/4fdwGafypabClGXfc7kTWQRJSgIgT3/KtfypBztiVQGFFde7DBmIAyJZ3wDGolCoYrJfywQ="}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.3.0_1528781139964_0.614273238291585"},"_hasShrinkwrap":false},"0.4.1":{"name":"schm-mongo","version":"0.4.1","description":"Extend schm schemas so as to work with MongoDB","license":"MIT","repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"main":"dist/index.js","author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"engines":{"node":">=6"},"scripts":{"test":"jest","coverage":"npm test -- --coverage","postcoverage":"opn coverage/lcov-report/index.html","lint":"eslint src test","flow":"flow","docs":"documentation readme src --section=API --pe flow -c documentation.yml","clean":"rimraf dist","prebuild":"npm run docs && npm run clean","build":"babel src -d dist --copy-files","preversion":"npm run lint && npm test && npm run build","postpublish":"npm run clean"},"jest":{"testEnvironment":"node"},"keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"dependencies":{"lodash":"^4.17.5"},"devDependencies":{"@babel/cli":"^7.0.0","documentation":"vicapow/documentation#a560a4373c301e37251f13e045811932c9c4ac01","eslint":"^5.5.0","flow-bin":"^0.80.0","jest-cli":"^23.6.0","opn-cli":"^3.1.0","rimraf":"^2.6.1","schm":"^0.4.1"},"peerDependencies":{"schm":"^0.4.0"},"gitHead":"8dfc542ab99c8d2cf50615561c12e48102eea0f8","_id":"schm-mongo@0.4.1","dist":{"shasum":"70ed2859f56f99aca770142aa91c861d431b7d29","tarball":"https://registry.npmjs.org/schm-mongo/-/schm-mongo-0.4.1.tgz","integrity":"sha512-bmHIc6c6Qmk3S9MmKn86U2/Rf/YW8c/8Geb7Ys2ZZAp89irt24dGDj44XffxqoteLpZrdjqT9959lxVJCHGPtA==","fileCount":13,"unpackedSize":29224,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbltIeCRA9TVsSAnZWagAA3e4P/iW7ipjUKfoV35u9LMPm\neXb8Dh03slGc7+8MnbYPWQifMdA8bUEOwm/dY1xtyVZ1OeXpydYzZYSzTVtE\ne2S7Z1GOibGbBQDagAFJp0Rwaj3oXPIfoqfM1TP8oRLO2z0ICCIKxYdw768O\nvF+9UOLzL3UBUB69reg7PdKd53pTlOARj4lLOA3baxjwgzDSeljotk3jo7cA\nec2H2xnuQqDTTYNKa0De2ZW1NSE+zCod5jV89Md+FqwLKK5+JcmdbZs/UTm8\nO4eBIsolijf++Ywm0aEEOjyCgsTY9yrQIel8Dyis7QaRS0Mai7PVETLXJx9A\n2nZitPUIgeNKMaTHyS9FcnEVv5uOOCHr79UhQGomTztKt4ARJAcA3vh4MQVe\nf+mFBLS/SSaf99z0uEpGqiKK78biEGQRLSVFHCxbMJymRVt8pdetRmsw2EHF\nXcWtIBUP0o8373y6vnpAB/lZg3DokcXUJ0CMHnJXVb5CAYjjrbniKrJhLq74\ndTIb9BUGNCv1EJUF+lP8lygXZXT5fPxbs8KBT7U/n4WiQBFmPnSWDlsxnTVa\nqJBc3+fOhtgwsZ6AQpgPnwRF7OxaCRYjBj4SeGfw8xoyYGK1jH1wjfRLNpmV\nYvD7kODP7TET2sO9GxwOROTp4wngStK4JnoLj6BIqUuu7CHH4dwPGQpBvbsw\nq5xC\r\n=NfOJ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD+BYd9RrblY8X1AlMgB/RrS7V/acE214+WVZiFfADvmQIhAMmA0xvZ6VWX2jL6Uo7dXY4Pe4P9qSZlIhTmBZdSyCfe"}]},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"_npmUser":{"name":"diegohaz","email":"hazdiego@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/schm-mongo_0.4.1_1536610845629_0.202864507743316"},"_hasShrinkwrap":false}},"time":{"created":"2018-03-10T17:47:57.935Z","0.1.0":"2018-03-10T17:47:57.977Z","modified":"2022-06-26T16:33:36.021Z","0.1.1":"2018-03-11T23:01:55.386Z","0.1.2":"2018-03-22T13:08:45.938Z","0.2.0":"2018-03-23T17:10:27.518Z","0.2.1":"2018-06-12T05:13:08.978Z","0.2.2":"2018-06-12T05:15:32.143Z","0.2.3":"2018-06-12T05:23:16.531Z","0.3.0":"2018-06-12T05:25:40.061Z","0.4.1":"2018-09-10T20:20:45.735Z"},"maintainers":[{"name":"diegohaz","email":"hazdiego@gmail.com"}],"description":"Extend schm schemas so as to work with MongoDB","keywords":["schm","schema","scheme","parser","validator","mongo","mongodb"],"repository":{"type":"git","url":"https://github.com/diegohaz/schm/tree/master/packages/schm-mongo"},"author":{"name":"Diego Haz","email":"hazdiego@gmail.com","url":"https://github.com/diegohaz"},"license":"MIT","readme":"# schm-mongo\n\n[![NPM version](https://img.shields.io/npm/v/schm-mongo.svg?style=flat-square)](https://npmjs.org/package/schm-mongo)\n\nComposable schema creators for parsing values to `MongoDB` queries.\n\n## Install\n\n    $ npm install --save schm-mongo\n\n## Usage\n\n```js\nconst schema = require('schm')\nconst { query, fields, page, near } = require('schm-mongo')\n\nconst placeSchema = schema({\n  name: String,\n  location: [Number],\n})\n\nconst querySchema = schema(\n  placeSchema,\n  query(),\n  fields(),\n  page(),\n  near('location'),\n)\n\n...\n\nconst { fields, page, ...query } = querySchema.parse({\n  fields: 'name',\n  near: '-22.4321,40.4321',\n  min_distance: 1000,\n  max_distance: 2000,\n  limit: 10,\n})\n/*\n  parsed:\n  {\n    location: { \n      $near: { \n        $geometry: { type: 'Point', coordinates: [-22.4321, 40.4321] },\n        $minDistance: 1000,\n        $maxDistance: 2000,\n      },\n    },\n    fields: { name: 1 },\n    page: {\n      limit: 10,\n    },\n  }\n*/\n\n// with mongodb driver\ndb.collection.find(query, fields)\n  .limit(page.limit)\n  .skip(page.skip)\n  .sort(page.sort)\n\n// with mongoose\nModel.find(query, fields, page)\n```\n\n## API\n\n<!-- Generated by documentation.js. Update this documentation by updating the source code. -->\n\n#### Table of Contents\n\n-   [query](#query)\n    -   [Parameters](#parameters)\n    -   [Examples](#examples)\n-   [fields](#fields)\n    -   [Examples](#examples-1)\n-   [page](#page)\n    -   [Examples](#examples-2)\n-   [near](#near)\n    -   [Parameters](#parameters-1)\n    -   [Examples](#examples-3)\n-   [Types](#types)\n    -   [PathsMap](#pathsmap)\n\n### query\n\nApplies `operator` parser to the schema. Also translates fields to paths.\n\n#### Parameters\n\n-   `pathsMap` **[PathsMap](#pathsmap)**  (optional, default `{}`)\n\n#### Examples\n\n```javascript\nconst schema = require('schm')\nconst { query } = require('schm-mongo')\n\nconst querySchema = schema({\n  name: String,\n  age: Number,\n}, query())\n\nconst parsed = querySchema.parse({ name: 'Haz', age: 27 })\n// {\n//   name: 'Haz',\n//   age: 27,\n// }\ndb.collection.find(parsed)\n```\n\n```javascript\nconst schema = require('schm')\nconst { query } = require('schm-mongo')\n\nconst querySchema = schema({\n  term: RegExp,\n  after: { type: Date, operator: '$gte' },\n  before: { type: Date, operator: '$lte' },\n}, query({\n  term: ['title', 'description'],\n  after: 'date',\n  before: 'date',\n}))\n\nconst parsed = querySchema.parse({\n  term: 'foo',\n  after: '2018-01-01',\n  before: '2018-03-03',\n})\n// {\n//   $and: [\n//     { $or: [{ title: /foo/i }, { description: /foo/i }] },\n//     { date: { $gte: 1514764800000 } },\n//     { date: { $lte: 1520035200000 } },\n//   ],\n// }\ndb.collection.find(parsed)\n```\n\nReturns **SchemaGroup** \n\n### fields\n\nDefines a `fields` parameter and parses it into [MongoDB projection](https://docs.mongodb.com/manual/tutorial/project-fields-from-query-results/).\n\n#### Examples\n\n```javascript\nconst schema = require('schm')\nconst { fields } = require('schm-mongo')\n\nconst fieldsSchema = schema(fields())\nconst parsed = fieldsSchema.parse({ fields: ['-_id', 'name'] })\n// {\n//   fields: {\n//     _id: 0,\n//     name: 1,\n//   }\n// }\ndb.collection.find({}, parsed.fields)\n```\n\n```javascript\n// Configuring fields parameter\nconst schema = require('schm')\nconst { fields } = require('schm-mongo')\n\nconst fieldsSchema = schema({\n  fields: {\n    type: String,\n    validate: [value => value._id !== 0, 'Cannot hide _id'],\n  },\n}, fields())\n\nfieldsSchema.validate({ fields: ['-_id'] }) // error\n```\n\n```javascript\n// Renaming fields\nconst schema = require('schm')\nconst translate = require('schm-translate')\nconst { fields } = require('schm-mongo')\n\nconst fieldsSchema = schema(\n  fields(),\n  translate({ fields: 'select' })\n)\n\nconst parsed = fieldsSchema.parse({ select: ['-_id', 'name'] })\n// {\n//   fields: {\n//     _id: 0,\n//     name: 1,\n//   }\n// }\ndb.collection.find({}, parsed.fields)\n```\n\nReturns **SchemaGroup** \n\n### page\n\nPagination: parses `page`, `limit` and `sort` parameters into properties to be used within [MongoDB cursor methods](https://docs.mongodb.com/manual/reference/method/js-cursor).\n\n#### Examples\n\n```javascript\nconst schema = require('schm')\nconst { page } = require('schm-mongo')\n\nconst pageSchema = schema(page())\nconst parsed = pageSchema.parse({ page: 3, limit: 30, sort: 'createdAt' })\n// {\n//   page: {\n//     limit: 30,\n//     skip: 60,\n//     sort: { createdAt: 1 },\n//   }\n// }\n```\n\n```javascript\n// Renaming page parameters\nconst schema = require('schm')\nconst translate = require('schm-translate')\nconst { page } = require('schm-mongo')\n\nconst pageSchema = schema(\n  page(),\n  translate({ page: 'p', limit: 'size', sort: 'sort_by' })\n)\nconst parsed = pageSchema.parse({ p: 3, size: 30, sort_by: 'createdAt' })\n// {\n//   page: {\n//     limit: 30,\n//     skip: 60,\n//     sort: { createdAt: 1 },\n//   }\n// }\n```\n\nReturns **SchemaGroup** \n\n### near\n\nCreates a [geospatial query](https://docs.mongodb.com/manual/geospatial-queries/) based on values.\n\n#### Parameters\n\n-   `param` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** \n\n#### Examples\n\n```javascript\nconst schema = require('schm')\nconst { near } = require('schm-mongo')\n\nconst nearSchema = schema(near('location'))\n\nconst parsed = nearSchema.parse({\n  near: '-20.4321,44.4321',\n  min_distance: 1000,\n  max_distance: 2000,\n})\n// {\n//   location: {\n//     $near: {\n//       $geometry: {\n//         type: 'Point',\n//         coordinates: [-20.4321, 44.4321],\n//       },\n//       $minDistance: 1000,\n//       $maxDistance: 2000,\n//     },\n//   }\n// }\n```\n\n```javascript\n// renaming near parameters\nconst schema = require('schm')\nconst translate = require('schm-translate')\nconst { near } = require('schm-mongo')\n\nconst nearSchema = schema(\n  near('location'),\n  translate({ near: 'lnglat', min_distance: 'min', max_distance: 'max' })\n)\n\nconst parsed = nearSchema.parse({\n  lnglat: '-20.4321,44.4321',\n  min: 1000,\n  max: 2000,\n})\n// {\n//   location: {\n//     $near: {\n//       $geometry: {\n//         type: 'Point',\n//         coordinates: [-20.4321, 44.4321],\n//       },\n//       $minDistance: 1000,\n//       $maxDistance: 2000,\n//     },\n//   }\n// }\n```\n\nReturns **SchemaGroup** \n\n### Types\n\n\n\n\n#### PathsMap\n\nType: {}\n\n## License\n\nMIT © [Diego Haz](https://github.com/diegohaz)\n","readmeFilename":"README.md"}