express-restify-mongoose 6.1.2 → 7.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,92 +1,92 @@
1
- Changelog
2
- =========
3
-
4
- ### 6.0.0
5
- > **This release requires mongoose ~5.8**
6
-
7
- * updated mongoose to version 5.8
8
-
9
- ### 5.0.0
10
-
11
- * dropped support for Node 4 and added support for Node 10
12
- * removed query operator parsing [#285](https://github.com/florianholzapfel/express-restify-mongoose/issues/285)
13
- * moved request query in req.erm.query [#299](https://github.com/florianholzapfel/express-restify-mongoose/issues/299) [#353](https://github.com/florianholzapfel/express-restify-mongoose/issues/353)
14
- * removed `next` from postProcess [#334](https://github.com/florianholzapfel/express-restify-mongoose/issues/334)
15
- * added error when skip and/or limit is not a valid integer
16
- * removed `_id` tinkering [#326](https://github.com/florianholzapfel/express-restify-mongoose/issues/326)
17
- * removed dependency on `async`
18
-
19
- ### 4.3.0
20
-
21
- * added support for async `outputFn` by returning a Promise
22
-
23
- ### 4.2.2
24
-
25
- * removed dependency on `lodash`, use specific modules and native methods when possible [#352](https://github.com/florianholzapfel/express-restify-mongoose/pull/352)
26
-
27
- ### 4.2.1
28
-
29
- * fixed issue [#294](https://github.com/florianholzapfel/express-restify-mongoose/issues/294)
30
-
31
- ### 4.2.0
32
-
33
- * removed `compile` step, code now runs natively on Node 4+ and `babel` is only used for coverage
34
-
35
- ### 4.1.1
36
-
37
- * fixed `distinct` queries when `options.totalCountHeader` is enabled
38
-
39
- ### 4.1.0
40
-
41
- * improved sync error handling in `buildQuery` by wrapping in a promise
42
- * fixed crash when `distinct` and `sort` operators were used in the same query
43
-
44
- ### 4.0.0
45
-
46
- * improved default error middleware by serializing error objects and removing stack traces
47
- * fixed Mongoose async middleware error propagation
48
- * fixed requests to always set `req.erm.statusCode`
49
- * removed `statusCode` from error object and response body
50
- * removed undocumented `outputFn` parameter, use `req.erm.result` and `req.erm.statusCode`
51
-
52
- ### 3.2.0
53
-
54
- * added an option to disable regex operations ([#195](https://github.com/florianholzapfel/express-restify-mongoose/issues/195))
55
- * fixed queries with an `idProperty` resulting in a `CastError` to return `404` instead of `400` ([#184](https://github.com/florianholzapfel/express-restify-mongoose/issues/184))
56
- * fixed query parser to handle geospatial operators ([#187](https://github.com/florianholzapfel/express-restify-mongoose/issues/187))
57
-
58
- ### 3.1.0
59
-
60
- * critical security fix with the `distinct` operator, see [issue #252](https://github.com/florianholzapfel/express-restify-mongoose/issues/252) for details
61
-
62
- ### 3.0.0
63
-
64
- * ported source to ES2015, compiled and published as ES5 with Babel
65
- * document filtering is now done right before output allowing access to the full document in post middleware
66
- * removed `options.lowercase` and `options.plural`, use `options.name = require('inflection').pluralize('modelName').toLowerCase()`
67
-
68
- ### 2.0.0
69
-
70
- * changed `serve` to no longer returns an Express 4 router, now returns the resource's base path (ie.: `/api/v1/Customer`)
71
- * changed `options.private` and `options.protected` to no longer accept comma separated fields, pass an array instead
72
- * removed `options.excluded`, use `options.private`
73
- * removed support for querying directly with query parameters, use `url?query={"name":"hello"}`
74
- * removed $and and $or query parameters, use `url?query={"$or":[...]}`
75
- * removed `prereq`, use `preMiddleware` instead
76
- * changed `postCreate`, `postUpdate`, and `postDelete` signatures to `(req, res, next)`
77
- * deprecated `outputFn`'s `data` parameter, data now available on `req.erm.result` and `req.erm.statusCode`
78
-
79
- ### 1.0.0
80
-
81
- > **This release requires mongoose ~4**
82
-
83
- * updated mongoose to version 4
84
- * removed `fullErrors`, implement a custom `onError` handler instead
85
- * removed `strict` option, allows DELETE without id and POST with id, disallows PUT without id
86
- * async `prereq` and `access` now use the standard `(err, data)` callback signature
87
- * `access` will throw an exception when an unsupported value is passed
88
- * changed `outputFn`'s signature to: `(req, res, { result: result, statusCode: statusCode })`
89
-
90
- ### 0.7.0
91
-
92
- > **This release requires mongoose ~3**
1
+ Changelog
2
+ =========
3
+
4
+ ### 6.0.0
5
+ > **This release requires mongoose ~5.8**
6
+
7
+ * updated mongoose to version 5.8
8
+
9
+ ### 5.0.0
10
+
11
+ * dropped support for Node 4 and added support for Node 10
12
+ * removed query operator parsing [#285](https://github.com/florianholzapfel/express-restify-mongoose/issues/285)
13
+ * moved request query in req.erm.query [#299](https://github.com/florianholzapfel/express-restify-mongoose/issues/299) [#353](https://github.com/florianholzapfel/express-restify-mongoose/issues/353)
14
+ * removed `next` from postProcess [#334](https://github.com/florianholzapfel/express-restify-mongoose/issues/334)
15
+ * added error when skip and/or limit is not a valid integer
16
+ * removed `_id` tinkering [#326](https://github.com/florianholzapfel/express-restify-mongoose/issues/326)
17
+ * removed dependency on `async`
18
+
19
+ ### 4.3.0
20
+
21
+ * added support for async `outputFn` by returning a Promise
22
+
23
+ ### 4.2.2
24
+
25
+ * removed dependency on `lodash`, use specific modules and native methods when possible [#352](https://github.com/florianholzapfel/express-restify-mongoose/pull/352)
26
+
27
+ ### 4.2.1
28
+
29
+ * fixed issue [#294](https://github.com/florianholzapfel/express-restify-mongoose/issues/294)
30
+
31
+ ### 4.2.0
32
+
33
+ * removed `compile` step, code now runs natively on Node 4+ and `babel` is only used for coverage
34
+
35
+ ### 4.1.1
36
+
37
+ * fixed `distinct` queries when `options.totalCountHeader` is enabled
38
+
39
+ ### 4.1.0
40
+
41
+ * improved sync error handling in `buildQuery` by wrapping in a promise
42
+ * fixed crash when `distinct` and `sort` operators were used in the same query
43
+
44
+ ### 4.0.0
45
+
46
+ * improved default error middleware by serializing error objects and removing stack traces
47
+ * fixed Mongoose async middleware error propagation
48
+ * fixed requests to always set `req.erm.statusCode`
49
+ * removed `statusCode` from error object and response body
50
+ * removed undocumented `outputFn` parameter, use `req.erm.result` and `req.erm.statusCode`
51
+
52
+ ### 3.2.0
53
+
54
+ * added an option to disable regex operations ([#195](https://github.com/florianholzapfel/express-restify-mongoose/issues/195))
55
+ * fixed queries with an `idProperty` resulting in a `CastError` to return `404` instead of `400` ([#184](https://github.com/florianholzapfel/express-restify-mongoose/issues/184))
56
+ * fixed query parser to handle geospatial operators ([#187](https://github.com/florianholzapfel/express-restify-mongoose/issues/187))
57
+
58
+ ### 3.1.0
59
+
60
+ * critical security fix with the `distinct` operator, see [issue #252](https://github.com/florianholzapfel/express-restify-mongoose/issues/252) for details
61
+
62
+ ### 3.0.0
63
+
64
+ * ported source to ES2015, compiled and published as ES5 with Babel
65
+ * document filtering is now done right before output allowing access to the full document in post middleware
66
+ * removed `options.lowercase` and `options.plural`, use `options.name = require('inflection').pluralize('modelName').toLowerCase()`
67
+
68
+ ### 2.0.0
69
+
70
+ * changed `serve` to no longer returns an Express 4 router, now returns the resource's base path (ie.: `/api/v1/Customer`)
71
+ * changed `options.private` and `options.protected` to no longer accept comma separated fields, pass an array instead
72
+ * removed `options.excluded`, use `options.private`
73
+ * removed support for querying directly with query parameters, use `url?query={"name":"hello"}`
74
+ * removed $and and $or query parameters, use `url?query={"$or":[...]}`
75
+ * removed `prereq`, use `preMiddleware` instead
76
+ * changed `postCreate`, `postUpdate`, and `postDelete` signatures to `(req, res, next)`
77
+ * deprecated `outputFn`'s `data` parameter, data now available on `req.erm.result` and `req.erm.statusCode`
78
+
79
+ ### 1.0.0
80
+
81
+ > **This release requires mongoose ~4**
82
+
83
+ * updated mongoose to version 4
84
+ * removed `fullErrors`, implement a custom `onError` handler instead
85
+ * removed `strict` option, allows DELETE without id and POST with id, disallows PUT without id
86
+ * async `prereq` and `access` now use the standard `(err, data)` callback signature
87
+ * `access` will throw an exception when an unsupported value is passed
88
+ * changed `outputFn`'s signature to: `(req, res, { result: result, statusCode: statusCode })`
89
+
90
+ ### 0.7.0
91
+
92
+ > **This release requires mongoose ~3**
package/LICENSE CHANGED
@@ -1,19 +1,19 @@
1
- Copyright (C) 2013 by Florian Holzapfel
2
-
3
- Permission is hereby granted, free of charge, to any person obtaining a copy
4
- of this software and associated documentation files (the "Software"), to deal
5
- in the Software without restriction, including without limitation the rights
6
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
- copies of the Software, and to permit persons to whom the Software is
8
- furnished to do so, subject to the following conditions:
9
-
10
- The above copyright notice and this permission notice shall be included in
11
- all copies or substantial portions of the Software.
12
-
13
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
- THE SOFTWARE.
1
+ Copyright (C) 2013 by Florian Holzapfel
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is
8
+ furnished to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in
11
+ all copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
+ THE SOFTWARE.
package/README.md CHANGED
@@ -1,52 +1,59 @@
1
- # express-restify-mongoose
2
-
3
- Easily create a flexible REST interface for mongoose models.
4
-
5
- [![Build Status](https://travis-ci.org/florianholzapfel/express-restify-mongoose.png)](https://travis-ci.org/florianholzapfel/express-restify-mongoose)
6
- [![Coverage Status](https://coveralls.io/repos/florianholzapfel/express-restify-mongoose/badge.svg?branch=master&service=github)](https://coveralls.io/github/florianholzapfel/express-restify-mongoose?branch=master)
7
- [![NPM version](https://badge.fury.io/js/express-restify-mongoose.png)](http://badge.fury.io/js/express-restify-mongoose)
8
- [![Dependencies](https://david-dm.org/florianholzapfel/express-restify-mongoose.png)](https://david-dm.org/florianholzapfel/express-restify-mongoose)
9
-
10
- ## Getting started
11
-
12
- > **From 6.0.0 onwards, the library is only compatible with mongoose >= 5.8. From 1.0.0 onwards, the library is only compatible with mongoose >= 4. For mongoose 3.x compatibility, use the 0.7.x branch.**
13
-
14
- ```sh
15
- npm install express-restify-mongoose --save
16
- ```
17
-
18
- ## Documentation
19
-
20
- [https://florianholzapfel.github.io/express-restify-mongoose/](https://florianholzapfel.github.io/express-restify-mongoose/)
21
-
22
- ## Contributing
23
-
24
- Found a bug or have a suggestion to make? Have a took at [issues or open a new one](https://github.com/florianholzapfel/express-restify-mongoose/issues).
25
-
26
- Everyone is welcome to contribute code by [creating a pull request](https://github.com/florianholzapfel/express-restify-mongoose/pulls), just make sure to follow [standard style](https://github.com/feross/standard).
27
-
28
- Many thanks to all [contributors](https://github.com/florianholzapfel/express-restify-mongoose/graphs/contributors)!
29
-
30
- ## License (MIT)
31
-
32
- ```
33
- Copyright (C) 2013 by Florian Holzapfel
34
-
35
- Permission is hereby granted, free of charge, to any person obtaining a copy
36
- of this software and associated documentation files (the "Software"), to deal
37
- in the Software without restriction, including without limitation the rights
38
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
39
- copies of the Software, and to permit persons to whom the Software is
40
- furnished to do so, subject to the following conditions:
41
-
42
- The above copyright notice and this permission notice shall be included in
43
- all copies or substantial portions of the Software.
44
-
45
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
46
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
47
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
48
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
49
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
50
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
51
- THE SOFTWARE.
52
- ```
1
+ # express-restify-mongoose
2
+
3
+ Easily create a flexible REST interface for mongoose models.
4
+
5
+ [![Build Status](https://github.com/florianholzapfel/express-restify-mongoose/actions/workflows/node.js.yml/badge.svg)](https://github.com/florianholzapfel/express-restify-mongoose/actions/workflows/node.js.yml)
6
+ [](https://sonarcloud.io/project/overview?id=florianholzapfel_express-restify-mongoose)
7
+ [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=florianholzapfel_express-restify-mongoose&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=florianholzapfel_express-restify-mongoose)
8
+ [![npm version](https://badge.fury.io/js/express-restify-mongoose.svg)](https://badge.fury.io/js/express-restify-mongoose)
9
+
10
+ ## Getting started
11
+
12
+ ```sh
13
+ npm install express-restify-mongoose --save
14
+ ```
15
+
16
+ ## Documentation
17
+
18
+ [https://florianholzapfel.github.io/express-restify-mongoose/](https://florianholzapfel.github.io/express-restify-mongoose/)
19
+
20
+ ## Compatibility
21
+
22
+ | This library | Mongoose |
23
+ | ------------ | -------- |
24
+ | >= 7.0.0 | >= 6.x |
25
+ | >= 6.0.0 | >= 5.8.0 |
26
+ | >= 1.0.0 | 4.x |
27
+ | 0.7.5 | 3.x |
28
+
29
+ ## Contributing
30
+
31
+ Found a bug or have a suggestion to make? Have a took at [issues or open a new one](https://github.com/florianholzapfel/express-restify-mongoose/issues).
32
+
33
+ Everyone is welcome to contribute code by [creating a pull request](https://github.com/florianholzapfel/express-restify-mongoose/pulls), just make sure to follow [standard style](https://github.com/feross/standard).
34
+
35
+ Many thanks to all [contributors](https://github.com/florianholzapfel/express-restify-mongoose/graphs/contributors)!
36
+
37
+ ## License (MIT)
38
+
39
+ ```
40
+ Copyright (C) 2013 by Florian Holzapfel
41
+
42
+ Permission is hereby granted, free of charge, to any person obtaining a copy
43
+ of this software and associated documentation files (the "Software"), to deal
44
+ in the Software without restriction, including without limitation the rights
45
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
46
+ copies of the Software, and to permit persons to whom the Software is
47
+ furnished to do so, subject to the following conditions:
48
+
49
+ The above copyright notice and this permission notice shall be included in
50
+ all copies or substantial portions of the Software.
51
+
52
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
53
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
54
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
55
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
56
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
57
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
58
+ THE SOFTWARE.
59
+ ```
package/index.d.ts ADDED
@@ -0,0 +1,45 @@
1
+ // Type definitions for express-restify-mongoose 3.2.0
2
+ // Project: https://github.com/florianholzapfel/express-restify-mongoose
3
+ // Definitions by: pedroraft <https://github.com/pedroraft> & ravishivt <https://github.com/ravishivt>
4
+ // Definitions: https://github.com/florianholzapfel/express-restify-mongoose
5
+ // TypeScript Version: 2.5.3
6
+
7
+ ///<reference types="express" />
8
+ ///<reference types="mongoose" />
9
+
10
+ // DOCS: https://florianholzapfel.github.io/express-restify-mongoose/
11
+ declare module 'express-restify-mongoose' {
12
+ import * as express from 'express';
13
+ import * as mongoose from 'mongoose';
14
+
15
+ export interface Options {
16
+ prefix?: string;
17
+ version?: string;
18
+ idProperty?: string;
19
+ restify?: boolean;
20
+ plural?: boolean;
21
+ lowercase?: boolean;
22
+ name?: string;
23
+ private?: string[];
24
+ protected?: string[];
25
+ lean?: boolean;
26
+ findOneAndUpdate?: boolean;
27
+ preMiddleware?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
28
+ preCreate?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
29
+ preRead?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
30
+ preUpdate?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
31
+ preDelete?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
32
+ access?: (req: express.Request, done?: any) => any;
33
+ contextFilter?: (model: mongoose.Model<any>, req: express.Request, done: any) => any;
34
+ postCreate?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
35
+ postRead?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
36
+ postUpdate?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
37
+ postDelete?: (req: express.Request, res: express.Response, next: express.NextFunction) => any;
38
+ outputFn?: (req: express.Request, res: express.Response) => any;
39
+ onError?: (err: any, req: express.Request, res: express.Response, next: express.NextFunction) => any;
40
+ }
41
+
42
+ export function serve(router: express.Router, mongooseModel: mongoose.Model<any>, options?: Options): string;
43
+
44
+ export function defaults(options: Options): void;
45
+ }
package/package.json CHANGED
@@ -1,85 +1,80 @@
1
- {
2
- "version": "6.1.2",
3
- "author": {
4
- "email": "flo.holzapfel@gmail.com",
5
- "name": "Florian Holzapfel"
6
- },
7
- "dependencies": {
8
- "ensure-array": "~1.0.0",
9
- "is-coordinates": "~2.0.0",
10
- "lodash.defaults": "~4.2.0",
11
- "lodash.get": "~4.4.2",
12
- "lodash.has": "~4.5.2",
13
- "lodash.isplainobject": "~4.0.6",
14
- "mongoose-detective": "~1.0.0",
15
- "moredots": "~1.0.1",
16
- "run-series": "~1.1.8",
17
- "serialize-error": "^7.0.1",
18
- "weedout": "~1.0.1"
19
- },
20
- "peerDependencies": {
21
- "mongoose": "^5.8.10"
22
- },
23
- "description": "Easily create a flexible REST interface for mongoose models",
24
- "devDependencies": {
25
- "babel-preset-es2015": "^6.24.0",
26
- "babel-register": "^6.26.0",
27
- "body-parser": "^1.19.0",
28
- "eslint": "^7.4.0",
29
- "eslint-config-prettier": "^6.11.0",
30
- "eslint-plugin-prettier": "^3.1.4",
31
- "express": "^4.17.1",
32
- "in-publish": "^2.0.1",
33
- "istanbul": "^0.4.5",
34
- "method-override": "^3.0.0",
35
- "mocha": "^8.0.1",
36
- "prettier": "^2.0.5",
37
- "request": "^2.88.2",
38
- "restify": "^8.5.1",
39
- "sinon": "^9.0.2"
40
- },
41
- "engines": {
42
- "node": ">=6"
43
- },
44
- "homepage": "http://florianholzapfel.github.io/express-restify-mongoose/",
45
- "keywords": [
46
- "ReST",
47
- "express",
48
- "restify",
49
- "mongodb",
50
- "mongoose",
51
- "model"
52
- ],
53
- "license": "MIT",
54
- "main": "./src/express-restify-mongoose",
55
- "name": "express-restify-mongoose",
56
- "readmeFilename": "README.md",
57
- "repository": {
58
- "type": "git",
59
- "url": "git://github.com/florianholzapfel/express-restify-mongoose.git"
60
- },
61
- "bugs": {
62
- "url": "https://github.com/florianholzapfel/express-restify-mongoose/issues"
63
- },
64
- "scripts": {
65
- "lint": "eslint . --ext .js",
66
- "pretest": "npm run lint",
67
- "test": "npm run test-unit && npm run test-filter && npm run test-express && npm run test-restify",
68
- "test-ci": "npm run test-unit && npm run test-filter && npm run test-cov-express && npm run test-restify",
69
- "test-unit": "mocha -R spec ./test/unit.js",
70
- "test-filter": "mocha -R spec ./test/integration/resource_filter.js --timeout 10s",
71
- "test-express": "mocha -R spec ./test/express.js --timeout 10s",
72
- "test-restify": "mocha -R spec ./test/restify.js --timeout 10s",
73
- "test-cov-unit": "istanbul cover node_modules/mocha/bin/_mocha -- --require babel-register -R spec ./test/unit.js",
74
- "test-cov-express": "istanbul cover node_modules/mocha/bin/_mocha -- --require babel-register -R spec ./test/express.js --timeout 10s",
75
- "test-cov-restify": "istanbul cover node_modules/mocha/bin/_mocha -- --require babel-register -R spec ./test/restify.js --timeout 10s",
76
- "report-coverage": "cat ./coverage/lcov.info | coveralls"
77
- },
78
- "types": "./index.d.ts",
79
- "files": [
80
- "CHANGELOG.md",
81
- "LICENSE",
82
- "README.md",
83
- "src/"
84
- ]
85
- }
1
+ {
2
+ "version": "7.0.2",
3
+ "author": {
4
+ "email": "flo.holzapfel@gmail.com",
5
+ "name": "Florian Holzapfel"
6
+ },
7
+ "dependencies": {
8
+ "ensure-array": "~1.0.0",
9
+ "is-coordinates": "~2.0.0",
10
+ "lodash.defaults": "~4.2.0",
11
+ "lodash.get": "~4.4.2",
12
+ "lodash.has": "~4.5.2",
13
+ "lodash.isplainobject": "~4.0.6",
14
+ "mongoose-detective": "~2.0.0",
15
+ "moredots": "~1.0.1",
16
+ "run-series": "~1.1.8",
17
+ "serialize-error": "^7.0.1",
18
+ "weedout": "~1.0.1"
19
+ },
20
+ "peerDependencies": {
21
+ "mongoose": "6.x"
22
+ },
23
+ "description": "Easily create a flexible REST interface for mongoose models",
24
+ "devDependencies": {
25
+ "body-parser": "^1.19.0",
26
+ "eslint": "^7.4.0",
27
+ "eslint-config-prettier": "^6.11.0",
28
+ "eslint-plugin-prettier": "^3.1.4",
29
+ "express": "^4.17.1",
30
+ "in-publish": "^2.0.1",
31
+ "method-override": "^3.0.0",
32
+ "mocha": "^10.1.0",
33
+ "prettier": "^2.0.5",
34
+ "request": "^2.88.2",
35
+ "restify": "^8.5.1",
36
+ "sinon": "^9.0.2"
37
+ },
38
+ "engines": {
39
+ "node": ">=14"
40
+ },
41
+ "homepage": "http://florianholzapfel.github.io/express-restify-mongoose/",
42
+ "keywords": [
43
+ "ReST",
44
+ "express",
45
+ "restify",
46
+ "mongodb",
47
+ "mongoose",
48
+ "model"
49
+ ],
50
+ "license": "MIT",
51
+ "main": "./src/express-restify-mongoose",
52
+ "name": "express-restify-mongoose",
53
+ "readmeFilename": "README.md",
54
+ "repository": {
55
+ "type": "git",
56
+ "url": "git://github.com/florianholzapfel/express-restify-mongoose.git"
57
+ },
58
+ "bugs": {
59
+ "url": "https://github.com/florianholzapfel/express-restify-mongoose/issues"
60
+ },
61
+ "scripts": {
62
+ "lint": "eslint . --ext .js",
63
+ "prepublish": "in-publish && npm test || not-in-publish",
64
+ "pretest": "npm run lint",
65
+ "test": "npm run test-unit && npm run test-filter && npm run test-express && npm run test-restify",
66
+ "test-ci": "npm run test-unit && npm run test-filter && npm run test-restify",
67
+ "test-unit": "mocha -R spec ./test/unit.js",
68
+ "test-filter": "mocha -R spec ./test/integration/resource_filter.js --timeout 10s",
69
+ "test-express": "mocha -R spec ./test/express.js --timeout 10s",
70
+ "test-restify": "mocha -R spec ./test/restify.js --timeout 10s"
71
+ },
72
+ "types": "./index.d.ts",
73
+ "files": [
74
+ "CHANGELOG.md",
75
+ "LICENSE",
76
+ "README.md",
77
+ "index.d.ts",
78
+ "src/"
79
+ ]
80
+ }