@lykmapipo/mongoose-common 0.38.3 → 0.40.0

Sign up to get free protection for your applications and to get access to all the features.
package/.babelrc ADDED
@@ -0,0 +1,12 @@
1
+ {
2
+ "presets": [
3
+ [
4
+ "@babel/preset-env",
5
+ {
6
+ "targets": {
7
+ "node": "current"
8
+ }
9
+ }
10
+ ]
11
+ ]
12
+ }
package/.editorconfig ADDED
@@ -0,0 +1,14 @@
1
+ # top-most EditorConfig file
2
+ root = true
3
+
4
+ # Unix-style newlines with a newline ending every file
5
+ [*]
6
+ end_of_line = lf
7
+ insert_final_newline = true
8
+ indent_style = space
9
+ indent_size = 2
10
+
11
+ # Matches multiple files with brace expansion notation
12
+ # Set default charset
13
+ [*.{js}]
14
+ charset = utf-8
package/.eslintignore ADDED
@@ -0,0 +1 @@
1
+ src/predefine.apidoc.js
package/.eslintrc ADDED
@@ -0,0 +1,11 @@
1
+ {
2
+ "extends": [
3
+ "airbnb-base",
4
+ "plugin:prettier/recommended",
5
+ "plugin:jsdoc/recommended"
6
+ ],
7
+ "plugins": ["prettier", "jsdoc"],
8
+ "rules": {
9
+ "prettier/prettier": "error"
10
+ }
11
+ }
package/.prettierignore CHANGED
@@ -1 +0,0 @@
1
- docs
package/CHANGELOG.md CHANGED
@@ -1,3 +1,42 @@
1
+ #### 0.40.0 (2021-09-27)
2
+
3
+ ##### Chores
4
+
5
+ * **release:** compile latest source ([6bd384a1](https://github.com/lykmapipo/mongoose-common/commit/6bd384a15405769b8ab437caae80b1a4cd0c324c))
6
+ * **deps:** force latest version & audit fix ([097ebf76](https://github.com/lykmapipo/mongoose-common/commit/097ebf76ef2811096edb315a0f95bf9b3067a23f))
7
+
8
+ ##### Other Changes
9
+
10
+ * migrate to mongoose v6 ([25d89389](https://github.com/lykmapipo/mongoose-common/commit/25d893893fff8ba94a3bc3978fab5f3abb316989))
11
+
12
+ ##### Refactors
13
+
14
+ * use named imports ([0713b619](https://github.com/lykmapipo/mongoose-common/commit/0713b619bf3a2457944597f105493a8547dbe4da))
15
+ * migrate to es6 ([a7aa7662](https://github.com/lykmapipo/mongoose-common/commit/a7aa76627f45fe9723a459852dabff57df50795e))
16
+
17
+ #### 0.39.0 (2020-12-29)
18
+
19
+ ##### Bug Fixes
20
+
21
+ * connect & disconnect failures ([a84456c0](https://github.com/lykmapipo/mongoose-common/commit/a84456c00a21c6e89f4b00c31347e69c1d1f5661))
22
+
23
+ #### 0.38.5 (2020-12-27)
24
+
25
+ ##### Chores
26
+
27
+ * **deps:**
28
+ * force latest version & audit fix ([de2ac84f](https://github.com/lykmapipo/mongoose-common/commit/de2ac84fdf5b6f4c12a3412aefd25d2f09998e04))
29
+ * bump bl from 2.2.0 to 2.2.1 ([06b6d44e](https://github.com/lykmapipo/mongoose-common/commit/06b6d44ea5646c3cf8f7c598199db45271c4ccca))
30
+ * bump dot-prop from 4.2.0 to 4.2.1 ([588c537c](https://github.com/lykmapipo/mongoose-common/commit/588c537cbdc2ef700f3034852f7d01c0cb7183d0))
31
+ * bump ini from 1.3.5 to 1.3.7 ([b649f9cf](https://github.com/lykmapipo/mongoose-common/commit/b649f9cf975c8607267c7ae6b8641532cc882842))
32
+ * bump websocket-extensions from 0.1.3 to 0.1.4 ([db5656c4](https://github.com/lykmapipo/mongoose-common/commit/db5656c44ff52848ecb2ab1512cf24c9e7045e8c))
33
+
34
+ #### 0.38.4 (2020-08-08)
35
+
36
+ ##### Chores
37
+
38
+ * **deps:** force latest version & audit fix ([f7ee608b](https://github.com/lykmapipo/mongoose-common/commit/f7ee608b3541c0c9fcd1d7b42c9d88e88ad70060))
39
+
1
40
  #### 0.38.3 (2020-07-29)
2
41
 
3
42
  ##### Chores
package/LICENSE CHANGED
@@ -1,9 +1,9 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2018 lykmapipo & Contributors
3
+ Copyright (c) lykmapipo & Contributors
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6
6
 
7
7
  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8
8
 
9
- THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
9
+ THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/README.md CHANGED
@@ -1,13 +1,25 @@
1
1
  # mongoose-common
2
2
 
3
- [![Build Status](https://travis-ci.org/lykmapipo/mongoose-common.svg?branch=master)](https://travis-ci.org/lykmapipo/mongoose-common)
4
- [![Dependencies Status](https://david-dm.org/lykmapipo/mongoose-common/status.svg)](https://david-dm.org/lykmapipo/mongoose-common)
3
+ [![Build Status](https://app.travis-ci.com/lykmapipo/mongoose-common.svg?branch=master)](https://app.travis-ci.com/lykmapipo/mongoose-common)
4
+ [![Dependencies Status](https://david-dm.org/lykmapipo/mongoose-common.svg)](https://david-dm.org/lykmapipo/mongoose-common)
5
+ [![Coverage Status](https://coveralls.io/repos/github/lykmapipo/mongoose-common/badge.svg?branch=master)](https://coveralls.io/github/lykmapipo/mongoose-common?branch=master)
6
+ [![GitHub License](https://img.shields.io/github/license/lykmapipo/mongoose-common)](https://github.com/lykmapipo/mongoose-common/blob/develop/LICENSE)
7
+
8
+ [![Commitizen Friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)
9
+ [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg)](https://github.com/prettier/prettier)
10
+ [![Code Style](https://badgen.net/badge/code%20style/airbnb/ff5a5f?icon=airbnb)](https://github.com/airbnb/javascript)
11
+ [![npm version](https://img.shields.io/npm/v/@lykmapipo/mongoose-common)](https://www.npmjs.com/package/@lykmapipo/mongoose-common)
5
12
 
6
13
  Re-usable helpers for mongoose
7
14
 
15
+ **Note: This version no longer support [mongoose-schema-jsonschema](https://github.com/DScheglov/mongoose-schema-jsonschema)**
16
+
8
17
  ## Requirements
9
18
 
10
- - NodeJS v9.3+
19
+ - [NodeJS v13+](https://nodejs.org)
20
+ - [Npm v6.12+](https://www.npmjs.com/)
21
+ - [MongoDB v4+](https://www.mongodb.com/)
22
+ - [Mongoose v6+](https://github.com/Automattic/mongoose)
11
23
 
12
24
  ## Install
13
25
  ```sh
@@ -17,13 +29,14 @@ $ npm install --save mongoose @lykmapipo/mongoose-common
17
29
  ## Usage
18
30
 
19
31
  ```javascript
20
- const {
32
+ import mongoose from 'mongoose';
33
+ import {
21
34
  connect,
22
35
  clear,
23
36
  syncIndexes,
24
37
  disconnect,
25
38
  drop
26
- } = require('@lykmapipo/mongoose-common');
39
+ } from '@lykmapipo/mongoose-common';
27
40
 
28
41
  connect(error => { ... });
29
42
 
@@ -192,13 +205,14 @@ $ npm test
192
205
  ## Contribute
193
206
  It will be nice, if you open an issue first so that we can know what is going on, then, fork this repo and push in your ideas. Do not forget to add a bit of test(s) of what value you adding.
194
207
 
195
- ## Licence
208
+ ## License
209
+
196
210
  The MIT License (MIT)
197
211
 
198
- Copyright (c) 2018 lykmapipo & Contributors
212
+ Copyright (c) CodeTanzania & Contributors
199
213
 
200
214
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
201
215
 
202
216
  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
203
217
 
204
- THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
218
+ THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/SECURITY.md ADDED
@@ -0,0 +1,3 @@
1
+ # Security
2
+
3
+ If you find a security vulnerability in mongoose-common, file a [new issue](https://github.com/lykmapipo/mongoose-common/issues).