@beecode/msh-util 1.0.2 → 1.1.0

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.
@@ -0,0 +1,13 @@
1
+ export declare const arrayUtil: {
2
+ /**
3
+ * Check if array is empty
4
+ * @template T
5
+ * @param {T | null | undefined} value
6
+ * @return {value is T}
7
+ * @example
8
+ * const arrayOfNumbers = [1, 2, undefined, 4, null, 6].filter(arrayUtil.notEmpty))
9
+ * console.log(arrayOfNumbers)// [1, 2, 4, 6]
10
+ */
11
+ notEmpty: <T>(value: T | null | undefined) => value is T;
12
+ };
13
+ //# sourceMappingURL=array-util.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array-util.d.ts","sourceRoot":"","sources":["../src/array-util.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS;IACrB;;;;;;;;OAQG;;CAIH,CAAA"}
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.arrayUtil = void 0;
4
+ exports.arrayUtil = {
5
+ /**
6
+ * Check if array is empty
7
+ * @template T
8
+ * @param {T | null | undefined} value
9
+ * @return {value is T}
10
+ * @example
11
+ * const arrayOfNumbers = [1, 2, undefined, 4, null, 6].filter(arrayUtil.notEmpty))
12
+ * console.log(arrayOfNumbers)// [1, 2, 4, 6]
13
+ */
14
+ notEmpty: (value) => {
15
+ return value !== null && value !== undefined;
16
+ },
17
+ };
18
+ //# sourceMappingURL=array-util.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array-util.js","sourceRoot":"","sources":["../src/array-util.ts"],"names":[],"mappings":";;;AAAa,QAAA,SAAS,GAAG;IACxB;;;;;;;;OAQG;IACH,QAAQ,EAAE,CAAI,KAA2B,EAAc,EAAE;QACxD,OAAO,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,CAAA;IAC7C,CAAC;CACD,CAAA"}
package/package.json CHANGED
@@ -18,16 +18,16 @@
18
18
  },
19
19
  "dependencies": {
20
20
  "date-fns": "2.29.3",
21
- "joi": "17.8.4",
21
+ "joi": "17.9.1",
22
22
  "lodash.clonedeep": "4.5.0",
23
23
  "rxjs": "7.8.0"
24
24
  },
25
25
  "description": "",
26
26
  "devDependencies": {
27
- "@commitlint/cli": "17.4.4",
27
+ "@commitlint/cli": "17.5.1",
28
28
  "@commitlint/config-conventional": "17.4.4",
29
- "@commitlint/prompt": "17.4.4",
30
- "@semantic-release/changelog": "6.0.2",
29
+ "@commitlint/prompt": "17.5.0",
30
+ "@semantic-release/changelog": "6.0.3",
31
31
  "@semantic-release/commit-analyzer": "9.0.2",
32
32
  "@semantic-release/exec": "6.0.3",
33
33
  "@semantic-release/git": "10.0.1",
@@ -35,12 +35,12 @@
35
35
  "@semantic-release/release-notes-generator": "10.0.3",
36
36
  "@types/jest": "29.5.0",
37
37
  "@types/lodash.clonedeep": "4.5.7",
38
- "@types/node": "18.15.3",
39
- "@typescript-eslint/eslint-plugin": "5.55.0",
40
- "@typescript-eslint/parser": "5.55.0",
38
+ "@types/node": "18.15.11",
39
+ "@typescript-eslint/eslint-plugin": "5.57.1",
40
+ "@typescript-eslint/parser": "5.57.1",
41
41
  "commitizen": "4.3.0",
42
- "eslint": "8.36.0",
43
- "eslint-config-prettier": "8.7.0",
42
+ "eslint": "8.37.0",
43
+ "eslint-config-prettier": "8.8.0",
44
44
  "eslint-plugin-import": "2.27.5",
45
45
  "eslint-plugin-jest": "27.2.1",
46
46
  "eslint-plugin-no-loops": "0.3.0",
@@ -52,15 +52,15 @@
52
52
  "jest-extended": "3.2.4",
53
53
  "lint-staged": "13.2.0",
54
54
  "markdown-toc": "1.2.0",
55
- "prettier": "2.8.4",
56
- "rimraf": "4.4.0",
57
- "semantic-release": "20.1.3",
55
+ "prettier": "2.8.7",
56
+ "rimraf": "4.4.1",
57
+ "semantic-release": "21.0.1",
58
58
  "source-map-support": "0.5.21",
59
- "ts-jest": "29.0.5",
59
+ "ts-jest": "29.1.0",
60
60
  "ts-node": "10.9.1",
61
- "tsc-alias": "1.8.3",
61
+ "tsc-alias": "1.8.5",
62
62
  "tsc-watch": "6.0.0",
63
- "typedoc": "0.23.27",
63
+ "typedoc": "0.23.28",
64
64
  "typedoc-plugin-markdown": "3.14.0",
65
65
  "typescript": "4.9.5"
66
66
  },
@@ -88,7 +88,7 @@
88
88
  "audit:fix": "npx --yes npm-force-resolutions",
89
89
  "build": "npm run clean && npm run tsc && npm run tsc:alias",
90
90
  "build:on-success": "npm run tsc:alias",
91
- "build:watch": "npm run tsc:watch --preserveWatchOutput --onSuccess \"npm run tsc:cleaner\" --onCompilationComplete \"npm run build:on-success\"",
91
+ "build:watch": "npm run tsc:watch --preserveWatchOutput --onSuccess 'npm run tsc:cleaner' --onCompilationComplete 'npm run build:on-success'",
92
92
  "bump-version": "npm --no-git-tag-version version",
93
93
  "clean": "rimraf ./lib/*",
94
94
  "commit": "git-cz",
@@ -111,8 +111,8 @@
111
111
  "semantic-release": "semantic-release",
112
112
  "semantic-release:check": "npm run semantic-release --dry-run --no-ci",
113
113
  "test": "npm run test:unit && npm run test:int ",
114
- "test:int": "#TZ=utc jest --config=./test/jest.config.json",
115
- "test:unit": "TZ=utc jest",
114
+ "test:int": "# TZ=utc jest --config=./jest-int.config.js",
115
+ "test:unit": "TZ=utc jest --config=./jest-unit.config.js",
116
116
  "test:unit:coverage": "npm run test:unit --coverage",
117
117
  "test:unit:coverage:publish": "codecov",
118
118
  "tsc": "tsc -p ./tsconfig-build.json",
@@ -125,5 +125,5 @@
125
125
  "tsc:watch": "tsc-watch -p tsconfig-build.json"
126
126
  },
127
127
  "types": "lib/index.d.ts",
128
- "version": "1.0.2"
128
+ "version": "1.1.0"
129
129
  }