@mongez/reinforcements 2.3.1 → 2.3.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/README.md +2 -0
- package/cjs/Random/random.d.ts +35 -35
- package/cjs/Random/random.js +65 -67
- package/cjs/Random/random.test.d.ts +2 -0
- package/cjs/array/average.d.ts +6 -6
- package/cjs/array/average.js +12 -15
- package/cjs/array/average.test.d.ts +2 -0
- package/cjs/array/chunk.d.ts +4 -4
- package/cjs/array/chunk.js +13 -15
- package/cjs/array/chunk.test.d.ts +2 -0
- package/cjs/array/count.d.ts +4 -4
- package/cjs/array/count.js +14 -17
- package/cjs/array/count.test.d.ts +2 -0
- package/cjs/array/countBy.d.ts +6 -6
- package/cjs/array/countBy.js +20 -23
- package/cjs/array/countBy.test.d.ts +2 -0
- package/cjs/array/even.d.ts +6 -6
- package/cjs/array/even.js +15 -18
- package/cjs/array/even.test.d.ts +2 -0
- package/cjs/array/evenIndexes.d.ts +4 -4
- package/cjs/array/evenIndexes.js +9 -11
- package/cjs/array/evenIndexes.test.d.ts +2 -0
- package/cjs/array/groupBy.d.ts +7 -7
- package/cjs/array/groupBy.js +45 -48
- package/cjs/array/groupBy.test.d.ts +2 -0
- package/cjs/array/max.d.ts +6 -6
- package/cjs/array/max.js +20 -23
- package/cjs/array/max.test.d.ts +2 -0
- package/cjs/array/median.d.ts +6 -6
- package/cjs/array/median.js +25 -28
- package/cjs/array/median.test.d.ts +2 -0
- package/cjs/array/min.d.ts +6 -6
- package/cjs/array/min.js +20 -23
- package/cjs/array/min.test.d.ts +2 -0
- package/cjs/array/odd.d.ts +6 -6
- package/cjs/array/odd.js +15 -18
- package/cjs/array/odd.test.d.ts +2 -0
- package/cjs/array/oddIndexes.d.ts +4 -4
- package/cjs/array/oddIndexes.js +9 -11
- package/cjs/array/oddIndexes.test.d.ts +2 -0
- package/cjs/array/pluck.d.ts +8 -8
- package/cjs/array/pluck.js +23 -26
- package/cjs/array/pluck.test.d.ts +2 -0
- package/cjs/array/pushUnique.d.ts +5 -5
- package/cjs/array/pushUnique.js +14 -16
- package/cjs/array/pushUnique.test.d.ts +2 -0
- package/cjs/array/range.d.ts +4 -4
- package/cjs/array/range.js +21 -23
- package/cjs/array/range.test.d.ts +2 -0
- package/cjs/array/sum.d.ts +6 -6
- package/cjs/array/sum.js +28 -31
- package/cjs/array/sum.test.d.ts +2 -0
- package/cjs/array/unique.d.ts +4 -4
- package/cjs/array/unique.js +14 -17
- package/cjs/array/unique.test.d.ts +2 -0
- package/cjs/array/unshiftUnique.d.ts +5 -5
- package/cjs/array/unshiftUnique.js +14 -16
- package/cjs/array/unshiftUnique.test.d.ts +2 -0
- package/cjs/index.d.ts +56 -56
- package/cjs/index.js +56 -59
- package/cjs/mixed/areEqual/areEqual.d.ts +4 -4
- package/cjs/mixed/areEqual/areEqual.js +23 -25
- package/cjs/mixed/areEqual/areEqual.test.d.ts +2 -0
- package/cjs/mixed/clone/clone.d.ts +4 -4
- package/cjs/mixed/clone/clone.js +12 -18
- package/cjs/mixed/clone/clone.test.d.ts +2 -0
- package/cjs/mixed/shuffle/shuffle.d.ts +4 -4
- package/cjs/mixed/shuffle/shuffle.js +14 -16
- package/cjs/mixed/shuffle/shuffle.test.d.ts +2 -0
- package/cjs/number/round.d.ts +4 -4
- package/cjs/number/round.js +9 -11
- package/cjs/object/except.d.ts +4 -4
- package/cjs/object/except.js +12 -15
- package/cjs/object/except.test.d.ts +2 -0
- package/cjs/object/flatten.d.ts +4 -4
- package/cjs/object/flatten.js +38 -40
- package/cjs/object/flatten.test.d.ts +2 -0
- package/cjs/object/get.d.ts +4 -4
- package/cjs/object/get.js +24 -26
- package/cjs/object/get.test.d.ts +2 -0
- package/cjs/object/map.d.ts +4 -4
- package/cjs/object/map.js +10 -12
- package/cjs/object/merge.d.ts +1 -1
- package/cjs/object/merge.js +99 -104
- package/cjs/object/merge.test.d.ts +2 -0
- package/cjs/object/only.d.ts +4 -4
- package/cjs/object/only.js +17 -20
- package/cjs/object/only.test.d.ts +2 -0
- package/cjs/object/set.d.ts +5 -5
- package/cjs/object/set.js +28 -30
- package/cjs/object/set.test.d.ts +2 -0
- package/cjs/object/sort.d.ts +4 -4
- package/cjs/object/sort.js +15 -17
- package/cjs/object/unset.d.ts +4 -4
- package/cjs/object/unset.js +23 -26
- package/cjs/object/unset.test.d.ts +2 -0
- package/cjs/string/capitalize.d.ts +6 -6
- package/cjs/string/capitalize.js +15 -18
- package/cjs/string/extension.d.ts +4 -4
- package/cjs/string/extension.js +11 -13
- package/cjs/string/initials.d.ts +4 -4
- package/cjs/string/initials.js +15 -17
- package/cjs/string/initials.test.d.ts +2 -0
- package/cjs/string/ltrim.d.ts +7 -7
- package/cjs/string/ltrim.js +15 -18
- package/cjs/string/readMoreChars.d.ts +5 -5
- package/cjs/string/readMoreChars.js +11 -13
- package/cjs/string/readMoreWords.d.ts +5 -5
- package/cjs/string/readMoreWords.js +14 -16
- package/cjs/string/removeFirst.d.ts +7 -7
- package/cjs/string/removeFirst.js +13 -16
- package/cjs/string/removeLast.d.ts +7 -7
- package/cjs/string/removeLast.js +13 -16
- package/cjs/string/repeatsOf.d.ts +7 -7
- package/cjs/string/repeatsOf.js +17 -19
- package/cjs/string/replaceAll.d.ts +8 -8
- package/cjs/string/replaceAll.js +14 -17
- package/cjs/string/replaceFirst.d.ts +8 -8
- package/cjs/string/replaceFirst.js +14 -17
- package/cjs/string/replaceLast.d.ts +8 -8
- package/cjs/string/replaceLast.js +21 -23
- package/cjs/string/rtrim.d.ts +7 -7
- package/cjs/string/rtrim.js +15 -18
- package/cjs/string/startsWithArabic.d.ts +2 -2
- package/cjs/string/startsWithArabic.js +13 -17
- package/cjs/string/toCamelCase.d.ts +1 -1
- package/cjs/string/toCamelCase.js +11 -14
- package/cjs/string/toCamelCase.test.d.ts +2 -0
- package/cjs/string/toInputName.d.ts +5 -5
- package/cjs/string/toInputName.js +21 -24
- package/cjs/string/toKebabCase.d.ts +4 -4
- package/cjs/string/toKebabCase.js +10 -13
- package/cjs/string/toKebabCase.test.d.ts +2 -0
- package/cjs/string/toSnakeCase.d.ts +7 -7
- package/cjs/string/toSnakeCase.js +20 -22
- package/cjs/string/toSnakeCase.test.d.ts +2 -0
- package/cjs/string/toStudlyCase.d.ts +9 -9
- package/cjs/string/toStudlyCase.js +19 -22
- package/cjs/string/trim.d.ts +7 -7
- package/cjs/string/trim.js +19 -22
- package/cjs/string/ucfirst.d.ts +6 -6
- package/cjs/string/ucfirst.js +11 -13
- package/cjs/types.d.ts +1 -1
- package/cjs/utils/debounce.d.ts +8 -8
- package/cjs/utils/debounce.js +16 -18
- package/cjs/utils/escapeRegex.d.ts +4 -4
- package/cjs/utils/escapeRegex.js +8 -10
- package/cjs/utils/escapeRegex.test.d.ts +2 -0
- package/esm/Random/random.d.ts +35 -35
- package/esm/Random/random.js +64 -65
- package/esm/Random/random.test.d.ts +2 -0
- package/esm/array/average.d.ts +6 -6
- package/esm/array/average.js +11 -13
- package/esm/array/average.test.d.ts +2 -0
- package/esm/array/chunk.d.ts +4 -4
- package/esm/array/chunk.js +12 -13
- package/esm/array/chunk.test.d.ts +2 -0
- package/esm/array/count.d.ts +4 -4
- package/esm/array/count.js +13 -15
- package/esm/array/count.test.d.ts +2 -0
- package/esm/array/countBy.d.ts +6 -6
- package/esm/array/countBy.js +19 -21
- package/esm/array/countBy.test.d.ts +2 -0
- package/esm/array/even.d.ts +6 -6
- package/esm/array/even.js +14 -16
- package/esm/array/even.test.d.ts +2 -0
- package/esm/array/evenIndexes.d.ts +4 -4
- package/esm/array/evenIndexes.js +8 -9
- package/esm/array/evenIndexes.test.d.ts +2 -0
- package/esm/array/groupBy.d.ts +7 -7
- package/esm/array/groupBy.js +44 -46
- package/esm/array/groupBy.test.d.ts +2 -0
- package/esm/array/max.d.ts +6 -6
- package/esm/array/max.js +19 -21
- package/esm/array/max.test.d.ts +2 -0
- package/esm/array/median.d.ts +6 -6
- package/esm/array/median.js +24 -26
- package/esm/array/median.test.d.ts +2 -0
- package/esm/array/min.d.ts +6 -6
- package/esm/array/min.js +19 -21
- package/esm/array/min.test.d.ts +2 -0
- package/esm/array/odd.d.ts +6 -6
- package/esm/array/odd.js +14 -16
- package/esm/array/odd.test.d.ts +2 -0
- package/esm/array/oddIndexes.d.ts +4 -4
- package/esm/array/oddIndexes.js +8 -9
- package/esm/array/oddIndexes.test.d.ts +2 -0
- package/esm/array/pluck.d.ts +8 -8
- package/esm/array/pluck.js +22 -24
- package/esm/array/pluck.test.d.ts +2 -0
- package/esm/array/pushUnique.d.ts +5 -5
- package/esm/array/pushUnique.js +13 -14
- package/esm/array/pushUnique.test.d.ts +2 -0
- package/esm/array/range.d.ts +4 -4
- package/esm/array/range.js +20 -21
- package/esm/array/range.test.d.ts +2 -0
- package/esm/array/sum.d.ts +6 -6
- package/esm/array/sum.js +27 -29
- package/esm/array/sum.test.d.ts +2 -0
- package/esm/array/unique.d.ts +4 -4
- package/esm/array/unique.js +13 -15
- package/esm/array/unique.test.d.ts +2 -0
- package/esm/array/unshiftUnique.d.ts +5 -5
- package/esm/array/unshiftUnique.js +13 -14
- package/esm/array/unshiftUnique.test.d.ts +2 -0
- package/esm/index.d.ts +56 -56
- package/esm/mixed/areEqual/areEqual.d.ts +4 -4
- package/esm/mixed/areEqual/areEqual.js +22 -23
- package/esm/mixed/areEqual/areEqual.test.d.ts +2 -0
- package/esm/mixed/clone/clone.d.ts +4 -4
- package/esm/mixed/clone/clone.js +11 -16
- package/esm/mixed/clone/clone.test.d.ts +2 -0
- package/esm/mixed/shuffle/shuffle.d.ts +4 -4
- package/esm/mixed/shuffle/shuffle.js +13 -14
- package/esm/mixed/shuffle/shuffle.test.d.ts +2 -0
- package/esm/number/round.d.ts +4 -4
- package/esm/number/round.js +8 -9
- package/esm/object/except.d.ts +4 -4
- package/esm/object/except.js +11 -13
- package/esm/object/except.test.d.ts +2 -0
- package/esm/object/flatten.d.ts +4 -4
- package/esm/object/flatten.js +37 -38
- package/esm/object/flatten.test.d.ts +2 -0
- package/esm/object/get.d.ts +4 -4
- package/esm/object/get.js +23 -24
- package/esm/object/get.test.d.ts +2 -0
- package/esm/object/map.d.ts +4 -4
- package/esm/object/map.js +9 -10
- package/esm/object/merge.d.ts +1 -1
- package/esm/object/merge.js +94 -96
- package/esm/object/merge.test.d.ts +2 -0
- package/esm/object/only.d.ts +4 -4
- package/esm/object/only.js +16 -18
- package/esm/object/only.test.d.ts +2 -0
- package/esm/object/set.d.ts +5 -5
- package/esm/object/set.js +27 -28
- package/esm/object/set.test.d.ts +2 -0
- package/esm/object/sort.d.ts +4 -4
- package/esm/object/sort.js +14 -15
- package/esm/object/unset.d.ts +4 -4
- package/esm/object/unset.js +22 -24
- package/esm/object/unset.test.d.ts +2 -0
- package/esm/string/capitalize.d.ts +6 -6
- package/esm/string/capitalize.js +14 -16
- package/esm/string/extension.d.ts +4 -4
- package/esm/string/extension.js +10 -11
- package/esm/string/initials.d.ts +4 -4
- package/esm/string/initials.js +14 -15
- package/esm/string/initials.test.d.ts +2 -0
- package/esm/string/ltrim.d.ts +7 -7
- package/esm/string/ltrim.js +14 -16
- package/esm/string/readMoreChars.d.ts +5 -5
- package/esm/string/readMoreChars.js +10 -11
- package/esm/string/readMoreWords.d.ts +5 -5
- package/esm/string/readMoreWords.js +13 -14
- package/esm/string/removeFirst.d.ts +7 -7
- package/esm/string/removeFirst.js +12 -14
- package/esm/string/removeLast.d.ts +7 -7
- package/esm/string/removeLast.js +12 -14
- package/esm/string/repeatsOf.d.ts +7 -7
- package/esm/string/repeatsOf.js +16 -17
- package/esm/string/replaceAll.d.ts +8 -8
- package/esm/string/replaceAll.js +13 -15
- package/esm/string/replaceFirst.d.ts +8 -8
- package/esm/string/replaceFirst.js +13 -15
- package/esm/string/replaceLast.d.ts +8 -8
- package/esm/string/replaceLast.js +20 -21
- package/esm/string/rtrim.d.ts +7 -7
- package/esm/string/rtrim.js +14 -16
- package/esm/string/startsWithArabic.d.ts +2 -2
- package/esm/string/startsWithArabic.js +10 -12
- package/esm/string/toCamelCase.d.ts +1 -1
- package/esm/string/toCamelCase.js +10 -12
- package/esm/string/toCamelCase.test.d.ts +2 -0
- package/esm/string/toInputName.d.ts +5 -5
- package/esm/string/toInputName.js +20 -22
- package/esm/string/toKebabCase.d.ts +4 -4
- package/esm/string/toKebabCase.js +9 -11
- package/esm/string/toKebabCase.test.d.ts +2 -0
- package/esm/string/toSnakeCase.d.ts +7 -7
- package/esm/string/toSnakeCase.js +19 -20
- package/esm/string/toSnakeCase.test.d.ts +2 -0
- package/esm/string/toStudlyCase.d.ts +9 -9
- package/esm/string/toStudlyCase.js +18 -20
- package/esm/string/trim.d.ts +7 -7
- package/esm/string/trim.js +18 -20
- package/esm/string/ucfirst.d.ts +6 -6
- package/esm/string/ucfirst.js +10 -11
- package/esm/types.d.ts +1 -1
- package/esm/utils/debounce.d.ts +8 -8
- package/esm/utils/debounce.js +15 -16
- package/esm/utils/escapeRegex.d.ts +4 -4
- package/esm/utils/escapeRegex.js +7 -8
- package/esm/utils/escapeRegex.test.d.ts +2 -0
- package/package.json +1 -1
package/cjs/index.d.ts
CHANGED
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
export { default as average, default as avg } from "./array/average";
|
|
2
|
-
export { default as chunk } from "./array/chunk";
|
|
3
|
-
export { default as count } from "./array/count";
|
|
4
|
-
export { default as countBy } from "./array/countBy";
|
|
5
|
-
export { default as even } from "./array/even";
|
|
6
|
-
export { default as evenIndexes } from "./array/evenIndexes";
|
|
7
|
-
export { default as groupBy } from "./array/groupBy";
|
|
8
|
-
export { default as max } from "./array/max";
|
|
9
|
-
export { default as median } from "./array/median";
|
|
10
|
-
export { default as min } from "./array/min";
|
|
11
|
-
export { default as odd } from "./array/odd";
|
|
12
|
-
export { default as oddIndexes } from "./array/oddIndexes";
|
|
13
|
-
export { default as pluck } from "./array/pluck";
|
|
14
|
-
export { default as pushUnique } from "./array/pushUnique";
|
|
15
|
-
export { default as range } from "./array/range";
|
|
16
|
-
export { default as sum } from "./array/sum";
|
|
17
|
-
export { default as unique } from "./array/unique";
|
|
18
|
-
export { default as unshiftUnique } from "./array/unshiftUnique";
|
|
19
|
-
export { default as areEqual } from "./mixed/areEqual/areEqual";
|
|
20
|
-
export { default as clone } from "./mixed/clone/clone";
|
|
21
|
-
export { default as shuffle } from "./mixed/shuffle/shuffle";
|
|
22
|
-
export { default as round } from "./number/round";
|
|
23
|
-
export { default as except } from "./object/except";
|
|
24
|
-
export { default as flatten } from "./object/flatten";
|
|
25
|
-
export { default as get } from "./object/get";
|
|
26
|
-
export { default as map } from "./object/map";
|
|
27
|
-
export { default as merge } from "./object/merge";
|
|
28
|
-
export { default as only } from "./object/only";
|
|
29
|
-
export { default as set } from "./object/set";
|
|
30
|
-
export { default as sort } from "./object/sort";
|
|
31
|
-
export { default as unset } from "./object/unset";
|
|
32
|
-
export { default as Random } from "./Random/random";
|
|
33
|
-
export { default as capitalize } from "./string/capitalize";
|
|
34
|
-
export { default as extension } from "./string/extension";
|
|
35
|
-
export { default as initials } from "./string/initials";
|
|
36
|
-
export { default as ltrim } from "./string/ltrim";
|
|
37
|
-
export { default as readMoreChars } from "./string/readMoreChars";
|
|
38
|
-
export { default as readMoreWords } from "./string/readMoreWords";
|
|
39
|
-
export { default as removeFirst } from "./string/removeFirst";
|
|
40
|
-
export { default as removeLast } from "./string/removeLast";
|
|
41
|
-
export { default as repeatsOf } from "./string/repeatsOf";
|
|
42
|
-
export { default as replaceAll } from "./string/replaceAll";
|
|
43
|
-
export { default as replaceFirst } from "./string/replaceFirst";
|
|
44
|
-
export { default as replaceLast } from "./string/replaceLast";
|
|
45
|
-
export { default as rtrim } from "./string/rtrim";
|
|
46
|
-
export { ARABIC_PATTERN, default as startsWithArabic, } from "./string/startsWithArabic";
|
|
47
|
-
export { default as toCamelCase } from "./string/toCamelCase";
|
|
48
|
-
export { default as toInputName } from "./string/toInputName";
|
|
49
|
-
export { default as toKebabCase } from "./string/toKebabCase";
|
|
50
|
-
export { default as toSnakeCase } from "./string/toSnakeCase";
|
|
51
|
-
export { default as toStudlyCase } from "./string/toStudlyCase";
|
|
52
|
-
export { default as trim } from "./string/trim";
|
|
53
|
-
export { default as ucfirst } from "./string/ucfirst";
|
|
54
|
-
export * from "./types";
|
|
55
|
-
export { default as debounce } from "./utils/debounce";
|
|
56
|
-
export { default as escapeRegex } from "./utils/escapeRegex";
|
|
1
|
+
export { default as average, default as avg } from "./array/average";
|
|
2
|
+
export { default as chunk } from "./array/chunk";
|
|
3
|
+
export { default as count } from "./array/count";
|
|
4
|
+
export { default as countBy } from "./array/countBy";
|
|
5
|
+
export { default as even } from "./array/even";
|
|
6
|
+
export { default as evenIndexes } from "./array/evenIndexes";
|
|
7
|
+
export { default as groupBy } from "./array/groupBy";
|
|
8
|
+
export { default as max } from "./array/max";
|
|
9
|
+
export { default as median } from "./array/median";
|
|
10
|
+
export { default as min } from "./array/min";
|
|
11
|
+
export { default as odd } from "./array/odd";
|
|
12
|
+
export { default as oddIndexes } from "./array/oddIndexes";
|
|
13
|
+
export { default as pluck } from "./array/pluck";
|
|
14
|
+
export { default as pushUnique } from "./array/pushUnique";
|
|
15
|
+
export { default as range } from "./array/range";
|
|
16
|
+
export { default as sum } from "./array/sum";
|
|
17
|
+
export { default as unique } from "./array/unique";
|
|
18
|
+
export { default as unshiftUnique } from "./array/unshiftUnique";
|
|
19
|
+
export { default as areEqual } from "./mixed/areEqual/areEqual";
|
|
20
|
+
export { default as clone } from "./mixed/clone/clone";
|
|
21
|
+
export { default as shuffle } from "./mixed/shuffle/shuffle";
|
|
22
|
+
export { default as round } from "./number/round";
|
|
23
|
+
export { default as except } from "./object/except";
|
|
24
|
+
export { default as flatten } from "./object/flatten";
|
|
25
|
+
export { default as get } from "./object/get";
|
|
26
|
+
export { default as map } from "./object/map";
|
|
27
|
+
export { default as merge } from "./object/merge";
|
|
28
|
+
export { default as only } from "./object/only";
|
|
29
|
+
export { default as set } from "./object/set";
|
|
30
|
+
export { default as sort } from "./object/sort";
|
|
31
|
+
export { default as unset } from "./object/unset";
|
|
32
|
+
export { default as Random } from "./Random/random";
|
|
33
|
+
export { default as capitalize } from "./string/capitalize";
|
|
34
|
+
export { default as extension } from "./string/extension";
|
|
35
|
+
export { default as initials } from "./string/initials";
|
|
36
|
+
export { default as ltrim } from "./string/ltrim";
|
|
37
|
+
export { default as readMoreChars } from "./string/readMoreChars";
|
|
38
|
+
export { default as readMoreWords } from "./string/readMoreWords";
|
|
39
|
+
export { default as removeFirst } from "./string/removeFirst";
|
|
40
|
+
export { default as removeLast } from "./string/removeLast";
|
|
41
|
+
export { default as repeatsOf } from "./string/repeatsOf";
|
|
42
|
+
export { default as replaceAll } from "./string/replaceAll";
|
|
43
|
+
export { default as replaceFirst } from "./string/replaceFirst";
|
|
44
|
+
export { default as replaceLast } from "./string/replaceLast";
|
|
45
|
+
export { default as rtrim } from "./string/rtrim";
|
|
46
|
+
export { ARABIC_PATTERN, default as startsWithArabic, } from "./string/startsWithArabic";
|
|
47
|
+
export { default as toCamelCase } from "./string/toCamelCase";
|
|
48
|
+
export { default as toInputName } from "./string/toInputName";
|
|
49
|
+
export { default as toKebabCase } from "./string/toKebabCase";
|
|
50
|
+
export { default as toSnakeCase } from "./string/toSnakeCase";
|
|
51
|
+
export { default as toStudlyCase } from "./string/toStudlyCase";
|
|
52
|
+
export { default as trim } from "./string/trim";
|
|
53
|
+
export { default as ucfirst } from "./string/ucfirst";
|
|
54
|
+
export * from "./types";
|
|
55
|
+
export { default as debounce } from "./utils/debounce";
|
|
56
|
+
export { default as escapeRegex } from "./utils/escapeRegex";
|
|
57
57
|
//# sourceMappingURL=index.d.ts.map
|
package/cjs/index.js
CHANGED
|
@@ -1,63 +1,60 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
var escapeRegex = require("./utils/escapeRegex.js");
|
|
60
|
-
|
|
3
|
+
var average = require("./array/average.js"),
|
|
4
|
+
chunk = require("./array/chunk.js"),
|
|
5
|
+
count = require("./array/count.js"),
|
|
6
|
+
countBy = require("./array/countBy.js"),
|
|
7
|
+
even = require("./array/even.js"),
|
|
8
|
+
evenIndexes = require("./array/evenIndexes.js"),
|
|
9
|
+
groupBy = require("./array/groupBy.js"),
|
|
10
|
+
max = require("./array/max.js"),
|
|
11
|
+
median = require("./array/median.js"),
|
|
12
|
+
min = require("./array/min.js"),
|
|
13
|
+
odd = require("./array/odd.js"),
|
|
14
|
+
oddIndexes = require("./array/oddIndexes.js"),
|
|
15
|
+
pluck = require("./array/pluck.js"),
|
|
16
|
+
pushUnique = require("./array/pushUnique.js"),
|
|
17
|
+
range = require("./array/range.js"),
|
|
18
|
+
sum = require("./array/sum.js"),
|
|
19
|
+
unique = require("./array/unique.js"),
|
|
20
|
+
unshiftUnique = require("./array/unshiftUnique.js"),
|
|
21
|
+
areEqual = require("./mixed/areEqual/areEqual.js"),
|
|
22
|
+
clone = require("./mixed/clone/clone.js"),
|
|
23
|
+
shuffle = require("./mixed/shuffle/shuffle.js"),
|
|
24
|
+
round = require("./number/round.js"),
|
|
25
|
+
except = require("./object/except.js"),
|
|
26
|
+
flatten = require("./object/flatten.js"),
|
|
27
|
+
get = require("./object/get.js"),
|
|
28
|
+
map = require("./object/map.js"),
|
|
29
|
+
merge = require("./object/merge.js"),
|
|
30
|
+
only = require("./object/only.js"),
|
|
31
|
+
set = require("./object/set.js"),
|
|
32
|
+
sort = require("./object/sort.js"),
|
|
33
|
+
unset = require("./object/unset.js"),
|
|
34
|
+
random = require("./Random/random.js"),
|
|
35
|
+
capitalize = require("./string/capitalize.js"),
|
|
36
|
+
extension = require("./string/extension.js"),
|
|
37
|
+
initials = require("./string/initials.js"),
|
|
38
|
+
ltrim = require("./string/ltrim.js"),
|
|
39
|
+
readMoreChars = require("./string/readMoreChars.js"),
|
|
40
|
+
readMoreWords = require("./string/readMoreWords.js"),
|
|
41
|
+
removeFirst = require("./string/removeFirst.js"),
|
|
42
|
+
removeLast = require("./string/removeLast.js"),
|
|
43
|
+
repeatsOf = require("./string/repeatsOf.js"),
|
|
44
|
+
replaceAll = require("./string/replaceAll.js"),
|
|
45
|
+
replaceFirst = require("./string/replaceFirst.js"),
|
|
46
|
+
replaceLast = require("./string/replaceLast.js"),
|
|
47
|
+
rtrim = require("./string/rtrim.js"),
|
|
48
|
+
startsWithArabic = require("./string/startsWithArabic.js"),
|
|
49
|
+
toCamelCase = require("./string/toCamelCase.js"),
|
|
50
|
+
toInputName = require("./string/toInputName.js"),
|
|
51
|
+
toKebabCase = require("./string/toKebabCase.js"),
|
|
52
|
+
toSnakeCase = require("./string/toSnakeCase.js"),
|
|
53
|
+
toStudlyCase = require("./string/toStudlyCase.js"),
|
|
54
|
+
trim = require("./string/trim.js"),
|
|
55
|
+
ucfirst = require("./string/ucfirst.js"),
|
|
56
|
+
debounce = require("./utils/debounce.js"),
|
|
57
|
+
escapeRegex = require("./utils/escapeRegex.js");
|
|
61
58
|
exports.average = average;
|
|
62
59
|
exports.avg = average;
|
|
63
60
|
exports.chunk = chunk;
|
|
@@ -105,7 +102,7 @@ exports.replaceFirst = replaceFirst;
|
|
|
105
102
|
exports.replaceLast = replaceLast;
|
|
106
103
|
exports.rtrim = rtrim;
|
|
107
104
|
exports.ARABIC_PATTERN = startsWithArabic.ARABIC_PATTERN;
|
|
108
|
-
exports.startsWithArabic = startsWithArabic
|
|
105
|
+
exports.startsWithArabic = startsWithArabic.default;
|
|
109
106
|
exports.toCamelCase = toCamelCase;
|
|
110
107
|
exports.toInputName = toInputName;
|
|
111
108
|
exports.toKebabCase = toKebabCase;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Determine if the given values are equal to each other
|
|
3
|
-
*/
|
|
4
|
-
export default function areEqual(value: any, value2: any): boolean;
|
|
1
|
+
/**
|
|
2
|
+
* Determine if the given values are equal to each other
|
|
3
|
+
*/
|
|
4
|
+
export default function areEqual(value: any, value2: any): boolean;
|
|
5
5
|
//# sourceMappingURL=areEqual.d.ts.map
|
|
@@ -1,25 +1,23 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
!
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
module.exports = areEqual;
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Determine if the given values are equal to each other
|
|
4
|
+
*/
|
|
5
|
+
function areEqual(value, value2) {
|
|
6
|
+
if (
|
|
7
|
+
["symbol", "number", "boolean", "string", "undefined"].includes(
|
|
8
|
+
typeof value,
|
|
9
|
+
) ||
|
|
10
|
+
!value ||
|
|
11
|
+
!value2
|
|
12
|
+
) {
|
|
13
|
+
return value === value2;
|
|
14
|
+
}
|
|
15
|
+
if (Array.isArray(value)) {
|
|
16
|
+
value = value.sort();
|
|
17
|
+
}
|
|
18
|
+
if (Array.isArray(value2)) {
|
|
19
|
+
value2 = value2.sort();
|
|
20
|
+
}
|
|
21
|
+
return JSON.stringify(value) === JSON.stringify(value2);
|
|
22
|
+
}
|
|
23
|
+
module.exports = areEqual;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Make a deep copy for the given object/array and its nested objects/arrays as well
|
|
3
|
-
*/
|
|
4
|
-
export default function clone(value: any): any;
|
|
1
|
+
/**
|
|
2
|
+
* Make a deep copy for the given object/array and its nested objects/arrays as well
|
|
3
|
+
*/
|
|
4
|
+
export default function clone(value: any): any;
|
|
5
5
|
//# sourceMappingURL=clone.d.ts.map
|
package/cjs/mixed/clone/clone.js
CHANGED
|
@@ -1,18 +1,12 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
return merge({}, value);
|
|
14
|
-
}
|
|
15
|
-
return value;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
module.exports = clone;
|
|
1
|
+
"use strict";
|
|
2
|
+
var merge = require("../../object/merge.js");
|
|
3
|
+
/**
|
|
4
|
+
* Make a deep copy for the given object/array and its nested objects/arrays as well
|
|
5
|
+
*/
|
|
6
|
+
function clone(value) {
|
|
7
|
+
if (value && (Array.isArray(value) || typeof value === "object")) {
|
|
8
|
+
return merge({}, value);
|
|
9
|
+
}
|
|
10
|
+
return value;
|
|
11
|
+
}
|
|
12
|
+
module.exports = clone;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Shuffle value either it is a string or an array
|
|
3
|
-
*/
|
|
4
|
-
export default function shuffle(value: any[] | string): any[] | string;
|
|
1
|
+
/**
|
|
2
|
+
* Shuffle value either it is a string or an array
|
|
3
|
+
*/
|
|
4
|
+
export default function shuffle(value: any[] | string): any[] | string;
|
|
5
5
|
//# sourceMappingURL=shuffle.d.ts.map
|
|
@@ -1,16 +1,14 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
module.exports = shuffle;
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Shuffle value either it is a string or an array
|
|
4
|
+
*/
|
|
5
|
+
function shuffle(value) {
|
|
6
|
+
if (!value || (!Array.isArray(value) && typeof value !== "string"))
|
|
7
|
+
return value;
|
|
8
|
+
if (typeof value === "string") {
|
|
9
|
+
return shuffle(value.split("")).join("");
|
|
10
|
+
}
|
|
11
|
+
if (!Array.isArray(value)) return value;
|
|
12
|
+
return value.sort(() => Math.random() - 0.5);
|
|
13
|
+
}
|
|
14
|
+
module.exports = shuffle;
|
package/cjs/number/round.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Round number with given precision
|
|
3
|
-
*/
|
|
4
|
-
export default function round(value: number, precision?: number): number;
|
|
1
|
+
/**
|
|
2
|
+
* Round number with given precision
|
|
3
|
+
*/
|
|
4
|
+
export default function round(value: number, precision?: number): number;
|
|
5
5
|
//# sourceMappingURL=round.d.ts.map
|
package/cjs/number/round.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
module.exports = round;
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Round number with given precision
|
|
4
|
+
*/
|
|
5
|
+
function round(value, precision = 2) {
|
|
6
|
+
const multiplier = Math.pow(10, precision || 0);
|
|
7
|
+
return Math.floor(value * multiplier) / multiplier;
|
|
8
|
+
}
|
|
9
|
+
module.exports = round;
|
package/cjs/object/except.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Get all object data except for the given keys using dot notation syntax
|
|
3
|
-
*/
|
|
4
|
-
export default function except(object: any, keys: Array<string>): any;
|
|
1
|
+
/**
|
|
2
|
+
* Get all object data except for the given keys using dot notation syntax
|
|
3
|
+
*/
|
|
4
|
+
export default function except(object: any, keys: Array<string>): any;
|
|
5
5
|
//# sourceMappingURL=except.d.ts.map
|
package/cjs/object/except.js
CHANGED
|
@@ -1,15 +1,12 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
module.exports = except;
|
|
1
|
+
"use strict";
|
|
2
|
+
var unset = require("./unset.js");
|
|
3
|
+
/**
|
|
4
|
+
* Get all object data except for the given keys using dot notation syntax
|
|
5
|
+
*/
|
|
6
|
+
function except(object, keys) {
|
|
7
|
+
if (!object || typeof object !== "object" || Array.isArray(object))
|
|
8
|
+
return object;
|
|
9
|
+
const newObject = { ...object };
|
|
10
|
+
return unset(newObject, keys);
|
|
11
|
+
}
|
|
12
|
+
module.exports = except;
|
package/cjs/object/flatten.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Flatten the given object into one big fat object
|
|
3
|
-
*/
|
|
4
|
-
export default function flatten(object: any, separator?: string, keepNestedOriginalObject?: boolean, parent?: string, root?: any): any;
|
|
1
|
+
/**
|
|
2
|
+
* Flatten the given object into one big fat object
|
|
3
|
+
*/
|
|
4
|
+
export default function flatten(object: any, separator?: string, keepNestedOriginalObject?: boolean, parent?: string, root?: any): any;
|
|
5
5
|
//# sourceMappingURL=flatten.d.ts.map
|
package/cjs/object/flatten.js
CHANGED
|
@@ -1,40 +1,38 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
) {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
const
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
module.exports = flatten;
|
|
1
|
+
"use strict";
|
|
2
|
+
function canBeFlatten(value) {
|
|
3
|
+
return value !== null && typeof value === "object";
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Flatten the given object into one big fat object
|
|
7
|
+
*/
|
|
8
|
+
function flatten(
|
|
9
|
+
object,
|
|
10
|
+
separator = ".",
|
|
11
|
+
keepNestedOriginalObject = false,
|
|
12
|
+
parent,
|
|
13
|
+
root = {},
|
|
14
|
+
) {
|
|
15
|
+
if (canBeFlatten(object) === false) {
|
|
16
|
+
return object;
|
|
17
|
+
}
|
|
18
|
+
// object = toPlainObject(object);
|
|
19
|
+
for (const key of Object.keys(object)) {
|
|
20
|
+
const value = object[key];
|
|
21
|
+
const keyChain = parent ? parent + separator + key : key;
|
|
22
|
+
if (
|
|
23
|
+
(Array.isArray(value) && value.length === 0) ||
|
|
24
|
+
typeof value === "function"
|
|
25
|
+
) {
|
|
26
|
+
root[keyChain] = value;
|
|
27
|
+
} else if (canBeFlatten(value)) {
|
|
28
|
+
if (keepNestedOriginalObject) {
|
|
29
|
+
root[keyChain] = value;
|
|
30
|
+
}
|
|
31
|
+
flatten(value, separator, keepNestedOriginalObject, keyChain, root);
|
|
32
|
+
} else {
|
|
33
|
+
root[keyChain] = value;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return root;
|
|
37
|
+
}
|
|
38
|
+
module.exports = flatten;
|
package/cjs/object/get.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Get the value of the given key
|
|
3
|
-
*/
|
|
4
|
-
export default function get(object: any, key: string, defaultValue?: any): any;
|
|
1
|
+
/**
|
|
2
|
+
* Get the value of the given key
|
|
3
|
+
*/
|
|
4
|
+
export default function get(object: any, key: string, defaultValue?: any): any;
|
|
5
5
|
//# sourceMappingURL=get.d.ts.map
|