@ls-stack/utils 3.62.0 → 3.63.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.
- package/dist/arrayUtils.cjs +5 -0
- package/dist/arrayUtils.d.cts +2 -1
- package/dist/arrayUtils.d.ts +2 -1
- package/dist/arrayUtils.js +3 -1
- package/dist/{chunk-2LO5FYP5.js → chunk-MI4UE2PQ.js} +1 -1
- package/dist/{chunk-GVIDV772.js → chunk-WFQJUJTC.js} +4 -0
- package/dist/{chunk-SGRS4OEE.js → chunk-ZXIKIA5B.js} +1 -1
- package/dist/concurrentCalls.js +1 -1
- package/dist/filterObjectOrArrayKeys.js +2 -2
- package/dist/objUtils.js +2 -2
- package/dist/serializeXML.js +1 -1
- package/dist/testUtils.js +3 -3
- package/package.json +1 -1
package/dist/arrayUtils.cjs
CHANGED
|
@@ -31,6 +31,7 @@ __export(arrayUtils_exports, {
|
|
|
31
31
|
hasDuplicates: () => hasDuplicates,
|
|
32
32
|
intersperse: () => intersperse,
|
|
33
33
|
isInArray: () => isInArray,
|
|
34
|
+
isInArrayWithoutNarrowing: () => isInArrayWithoutNarrowing,
|
|
34
35
|
looseIsInArray: () => looseIsInArray,
|
|
35
36
|
rejectArrayUndefinedValues: () => rejectArrayUndefinedValues,
|
|
36
37
|
rejectDuplicates: () => rejectDuplicates,
|
|
@@ -106,6 +107,9 @@ function isInArray(value, oneOf) {
|
|
|
106
107
|
}
|
|
107
108
|
return false;
|
|
108
109
|
}
|
|
110
|
+
function isInArrayWithoutNarrowing(value, oneOf) {
|
|
111
|
+
return oneOf.includes(value);
|
|
112
|
+
}
|
|
109
113
|
function looseIsInArray(value, array) {
|
|
110
114
|
return array.includes(value);
|
|
111
115
|
}
|
|
@@ -215,6 +219,7 @@ function repeat(value, count, separator) {
|
|
|
215
219
|
hasDuplicates,
|
|
216
220
|
intersperse,
|
|
217
221
|
isInArray,
|
|
222
|
+
isInArrayWithoutNarrowing,
|
|
218
223
|
looseIsInArray,
|
|
219
224
|
rejectArrayUndefinedValues,
|
|
220
225
|
rejectDuplicates,
|
package/dist/arrayUtils.d.cts
CHANGED
|
@@ -76,6 +76,7 @@ declare function arrayWithPrevAndIndex<T>(array: T[]): {
|
|
|
76
76
|
index: number;
|
|
77
77
|
}[];
|
|
78
78
|
declare function isInArray<T, const U extends T>(value: T, oneOf: readonly U[]): value is U;
|
|
79
|
+
declare function isInArrayWithoutNarrowing<T, const U extends T>(value: T, oneOf: readonly U[]): boolean;
|
|
79
80
|
declare function looseIsInArray(value: unknown, array: readonly unknown[]): boolean;
|
|
80
81
|
declare function findAfterIndex<T>(array: T[], index: number, predicate: (item: T) => boolean): T | undefined;
|
|
81
82
|
declare function findBeforeIndex<T>(array: T[], index: number, predicate: (item: T) => boolean): T | undefined;
|
|
@@ -167,4 +168,4 @@ declare function intersperse<T, I>(array: T[], separator: I): (T | I)[];
|
|
|
167
168
|
*/
|
|
168
169
|
declare function repeat<T>(value: T, count: number, separator?: T): T[];
|
|
169
170
|
|
|
170
|
-
export { type FilterAndMapReturn, type SortByProps, type SortByValueFn, arrayOps, arrayWithPrev, arrayWithPrevAndIndex, filterAndMap, findAfterIndex, findAndMap, findBeforeIndex, getAscIndexOrder, hasDuplicates, intersperse, isInArray, looseIsInArray, rejectArrayUndefinedValues, rejectDuplicates, repeat, sortBy, truncateArray };
|
|
171
|
+
export { type FilterAndMapReturn, type SortByProps, type SortByValueFn, arrayOps, arrayWithPrev, arrayWithPrevAndIndex, filterAndMap, findAfterIndex, findAndMap, findBeforeIndex, getAscIndexOrder, hasDuplicates, intersperse, isInArray, isInArrayWithoutNarrowing, looseIsInArray, rejectArrayUndefinedValues, rejectDuplicates, repeat, sortBy, truncateArray };
|
package/dist/arrayUtils.d.ts
CHANGED
|
@@ -76,6 +76,7 @@ declare function arrayWithPrevAndIndex<T>(array: T[]): {
|
|
|
76
76
|
index: number;
|
|
77
77
|
}[];
|
|
78
78
|
declare function isInArray<T, const U extends T>(value: T, oneOf: readonly U[]): value is U;
|
|
79
|
+
declare function isInArrayWithoutNarrowing<T, const U extends T>(value: T, oneOf: readonly U[]): boolean;
|
|
79
80
|
declare function looseIsInArray(value: unknown, array: readonly unknown[]): boolean;
|
|
80
81
|
declare function findAfterIndex<T>(array: T[], index: number, predicate: (item: T) => boolean): T | undefined;
|
|
81
82
|
declare function findBeforeIndex<T>(array: T[], index: number, predicate: (item: T) => boolean): T | undefined;
|
|
@@ -167,4 +168,4 @@ declare function intersperse<T, I>(array: T[], separator: I): (T | I)[];
|
|
|
167
168
|
*/
|
|
168
169
|
declare function repeat<T>(value: T, count: number, separator?: T): T[];
|
|
169
170
|
|
|
170
|
-
export { type FilterAndMapReturn, type SortByProps, type SortByValueFn, arrayOps, arrayWithPrev, arrayWithPrevAndIndex, filterAndMap, findAfterIndex, findAndMap, findBeforeIndex, getAscIndexOrder, hasDuplicates, intersperse, isInArray, looseIsInArray, rejectArrayUndefinedValues, rejectDuplicates, repeat, sortBy, truncateArray };
|
|
171
|
+
export { type FilterAndMapReturn, type SortByProps, type SortByValueFn, arrayOps, arrayWithPrev, arrayWithPrevAndIndex, filterAndMap, findAfterIndex, findAndMap, findBeforeIndex, getAscIndexOrder, hasDuplicates, intersperse, isInArray, isInArrayWithoutNarrowing, looseIsInArray, rejectArrayUndefinedValues, rejectDuplicates, repeat, sortBy, truncateArray };
|
package/dist/arrayUtils.js
CHANGED
|
@@ -10,13 +10,14 @@ import {
|
|
|
10
10
|
hasDuplicates,
|
|
11
11
|
intersperse,
|
|
12
12
|
isInArray,
|
|
13
|
+
isInArrayWithoutNarrowing,
|
|
13
14
|
looseIsInArray,
|
|
14
15
|
rejectArrayUndefinedValues,
|
|
15
16
|
rejectDuplicates,
|
|
16
17
|
repeat,
|
|
17
18
|
sortBy,
|
|
18
19
|
truncateArray
|
|
19
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-WFQJUJTC.js";
|
|
20
21
|
import "./chunk-C2SVCIWE.js";
|
|
21
22
|
import "./chunk-JF2MDHOJ.js";
|
|
22
23
|
export {
|
|
@@ -31,6 +32,7 @@ export {
|
|
|
31
32
|
hasDuplicates,
|
|
32
33
|
intersperse,
|
|
33
34
|
isInArray,
|
|
35
|
+
isInArrayWithoutNarrowing,
|
|
34
36
|
looseIsInArray,
|
|
35
37
|
rejectArrayUndefinedValues,
|
|
36
38
|
rejectDuplicates,
|
|
@@ -60,6 +60,9 @@ function isInArray(value, oneOf) {
|
|
|
60
60
|
}
|
|
61
61
|
return false;
|
|
62
62
|
}
|
|
63
|
+
function isInArrayWithoutNarrowing(value, oneOf) {
|
|
64
|
+
return oneOf.includes(value);
|
|
65
|
+
}
|
|
63
66
|
function looseIsInArray(value, array) {
|
|
64
67
|
return array.includes(value);
|
|
65
68
|
}
|
|
@@ -164,6 +167,7 @@ export {
|
|
|
164
167
|
arrayWithPrev,
|
|
165
168
|
arrayWithPrevAndIndex,
|
|
166
169
|
isInArray,
|
|
170
|
+
isInArrayWithoutNarrowing,
|
|
167
171
|
looseIsInArray,
|
|
168
172
|
findAfterIndex,
|
|
169
173
|
findBeforeIndex,
|
package/dist/concurrentCalls.js
CHANGED
package/dist/objUtils.js
CHANGED
|
@@ -14,9 +14,9 @@ import {
|
|
|
14
14
|
pick,
|
|
15
15
|
rejectObjUndefinedValues,
|
|
16
16
|
sortObjectKeys
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-ZXIKIA5B.js";
|
|
18
18
|
import "./chunk-GMJTLFM6.js";
|
|
19
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-WFQJUJTC.js";
|
|
20
20
|
import "./chunk-C2SVCIWE.js";
|
|
21
21
|
import "./chunk-JF2MDHOJ.js";
|
|
22
22
|
export {
|
package/dist/serializeXML.js
CHANGED
package/dist/testUtils.js
CHANGED
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
omit,
|
|
6
6
|
pick
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-ZXIKIA5B.js";
|
|
8
8
|
import "./chunk-GMJTLFM6.js";
|
|
9
9
|
import {
|
|
10
10
|
filterObjectOrArrayKeys
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-MI4UE2PQ.js";
|
|
12
12
|
import "./chunk-IATIXMCE.js";
|
|
13
13
|
import {
|
|
14
14
|
deepEqual
|
|
@@ -26,7 +26,7 @@ import "./chunk-BM4PYVOX.js";
|
|
|
26
26
|
import {
|
|
27
27
|
arrayWithPrevAndIndex,
|
|
28
28
|
filterAndMap
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-WFQJUJTC.js";
|
|
30
30
|
import {
|
|
31
31
|
isObject
|
|
32
32
|
} from "./chunk-C2SVCIWE.js";
|