es-toolkit 1.2.0 → 1.2.1-dev.61

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.
Files changed (160) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/LICENSE +21 -0
  3. package/README.md +2 -2
  4. package/dist/array/differenceWith.d.mts +1 -1
  5. package/dist/array/differenceWith.d.ts +1 -1
  6. package/dist/array/differenceWith.js.map +1 -1
  7. package/dist/array/differenceWith.mjs +1 -1
  8. package/dist/array/drop.d.mts +1 -1
  9. package/dist/array/drop.d.ts +1 -1
  10. package/dist/array/drop.js.map +1 -1
  11. package/dist/array/drop.mjs +1 -1
  12. package/dist/array/dropRight.d.mts +1 -1
  13. package/dist/array/dropRight.d.ts +1 -1
  14. package/dist/array/dropRight.js.map +1 -1
  15. package/dist/array/dropRight.mjs +1 -1
  16. package/dist/array/dropRightWhile.d.mts +1 -1
  17. package/dist/array/dropRightWhile.d.ts +1 -1
  18. package/dist/array/dropRightWhile.js.map +1 -1
  19. package/dist/array/dropRightWhile.mjs +1 -1
  20. package/dist/array/index.js.map +1 -1
  21. package/dist/array/index.mjs +35 -35
  22. package/dist/array/intersectionWith.d.mts +1 -1
  23. package/dist/array/intersectionWith.d.ts +1 -1
  24. package/dist/array/intersectionWith.js.map +1 -1
  25. package/dist/array/intersectionWith.mjs +1 -1
  26. package/dist/array/take.js.map +1 -1
  27. package/dist/array/take.mjs +1 -1
  28. package/dist/array/union.js.map +1 -1
  29. package/dist/array/union.mjs +2 -2
  30. package/dist/array/unionBy.d.mts +1 -1
  31. package/dist/array/unionBy.d.ts +1 -1
  32. package/dist/array/unionBy.js.map +1 -1
  33. package/dist/array/unionBy.mjs +1 -1
  34. package/dist/array/unionWith.js.map +1 -1
  35. package/dist/array/unionWith.mjs +2 -2
  36. package/dist/array/uniq.d.mts +1 -1
  37. package/dist/array/uniq.d.ts +1 -1
  38. package/dist/array/uniq.js.map +1 -1
  39. package/dist/array/uniq.mjs +1 -1
  40. package/dist/array/uniqBy.d.mts +4 -0
  41. package/dist/array/uniqBy.d.ts +4 -0
  42. package/dist/array/uniqBy.js.map +1 -1
  43. package/dist/array/uniqBy.mjs +2 -2
  44. package/dist/array/uniqWith.d.mts +5 -1
  45. package/dist/array/uniqWith.d.ts +5 -1
  46. package/dist/array/uniqWith.js.map +1 -1
  47. package/dist/array/uniqWith.mjs +1 -1
  48. package/dist/array/xor.js.map +1 -1
  49. package/dist/array/xor.mjs +3 -3
  50. package/dist/array/xorBy.d.mts +1 -1
  51. package/dist/array/xorBy.d.ts +1 -1
  52. package/dist/array/xorBy.js.map +1 -1
  53. package/dist/array/xorBy.mjs +2 -2
  54. package/dist/array/xorWith.js.map +1 -1
  55. package/dist/array/xorWith.mjs +5 -5
  56. package/dist/array/zipWith.d.mts +1 -1
  57. package/dist/array/zipWith.d.ts +1 -1
  58. package/dist/array/zipWith.js.map +1 -1
  59. package/dist/array/zipWith.mjs +1 -1
  60. package/dist/{chunk-6BCRFIEW.mjs → chunk-25R2U4KM.mjs} +1 -1
  61. package/dist/{chunk-6BCRFIEW.mjs.map → chunk-25R2U4KM.mjs.map} +1 -1
  62. package/dist/{chunk-VKVA56XG.mjs → chunk-3GMXDQQQ.mjs} +2 -2
  63. package/dist/{chunk-OLBUAFBX.mjs → chunk-4RRRH7OY.mjs} +1 -1
  64. package/dist/{chunk-OLBUAFBX.mjs.map → chunk-4RRRH7OY.mjs.map} +1 -1
  65. package/dist/{chunk-M3SHJ3LL.mjs → chunk-5NSVMWDQ.mjs} +1 -1
  66. package/dist/{chunk-M3SHJ3LL.mjs.map → chunk-5NSVMWDQ.mjs.map} +1 -1
  67. package/dist/{chunk-7LAOIS6P.mjs → chunk-6Z2YFKXQ.mjs} +1 -1
  68. package/dist/{chunk-7LAOIS6P.mjs.map → chunk-6Z2YFKXQ.mjs.map} +1 -1
  69. package/dist/{chunk-B5P232BA.mjs → chunk-7OU22ENP.mjs} +1 -1
  70. package/dist/chunk-7OU22ENP.mjs.map +1 -0
  71. package/dist/{chunk-YEZIGQJG.mjs → chunk-AB3DGGY3.mjs} +2 -2
  72. package/dist/{chunk-Y6ZRNII6.mjs → chunk-AIRSKN47.mjs} +1 -1
  73. package/dist/{chunk-Y6ZRNII6.mjs.map → chunk-AIRSKN47.mjs.map} +1 -1
  74. package/dist/{chunk-PRTIPC5X.mjs → chunk-C4IZ7TGA.mjs} +1 -1
  75. package/dist/chunk-C4IZ7TGA.mjs.map +1 -0
  76. package/dist/{chunk-SQOYF647.mjs → chunk-DVRGUUQG.mjs} +1 -1
  77. package/dist/chunk-DVRGUUQG.mjs.map +1 -0
  78. package/dist/{chunk-6GRNTXI3.mjs → chunk-EXU45QAF.mjs} +1 -1
  79. package/dist/{chunk-6GRNTXI3.mjs.map → chunk-EXU45QAF.mjs.map} +1 -1
  80. package/dist/{chunk-GLAZTR32.mjs → chunk-I2NAKQIE.mjs} +2 -2
  81. package/dist/{chunk-TK2EDHSP.mjs → chunk-JD42XAYW.mjs} +2 -2
  82. package/dist/chunk-JD42XAYW.mjs.map +1 -0
  83. package/dist/{chunk-SPLO5OZW.mjs → chunk-LIXL7PEP.mjs} +1 -1
  84. package/dist/chunk-LIXL7PEP.mjs.map +1 -0
  85. package/dist/{chunk-RK6PRCEJ.mjs → chunk-MLCL773E.mjs} +1 -1
  86. package/dist/chunk-MLCL773E.mjs.map +1 -0
  87. package/dist/{chunk-4PNP6CKQ.mjs → chunk-MTT7OPUK.mjs} +2 -2
  88. package/dist/chunk-MTT7OPUK.mjs.map +1 -0
  89. package/dist/{chunk-AFYV2UVZ.mjs → chunk-OFWKFUFZ.mjs} +1 -1
  90. package/dist/{chunk-AFYV2UVZ.mjs.map → chunk-OFWKFUFZ.mjs.map} +1 -1
  91. package/dist/{chunk-KBJTBR5T.mjs → chunk-OHQAR5AU.mjs} +1 -1
  92. package/dist/{chunk-KBJTBR5T.mjs.map → chunk-OHQAR5AU.mjs.map} +1 -1
  93. package/dist/{chunk-J6SWM4X6.mjs → chunk-PLTO44KM.mjs} +1 -1
  94. package/dist/chunk-PLTO44KM.mjs.map +1 -0
  95. package/dist/{chunk-TCHT4HCP.mjs → chunk-S3ZF7ZPG.mjs} +4 -4
  96. package/dist/{chunk-JDMFIUGM.mjs → chunk-SWPLMJR7.mjs} +1 -1
  97. package/dist/chunk-SWPLMJR7.mjs.map +1 -0
  98. package/dist/{chunk-YHY2XTJW.mjs → chunk-V7E5DGZP.mjs} +1 -1
  99. package/dist/chunk-V7E5DGZP.mjs.map +1 -0
  100. package/dist/{chunk-HOQRMBSB.mjs → chunk-VH2PV426.mjs} +1 -1
  101. package/dist/{chunk-HOQRMBSB.mjs.map → chunk-VH2PV426.mjs.map} +1 -1
  102. package/dist/{chunk-6LDIBBWQ.mjs → chunk-VOAKEOIM.mjs} +1 -1
  103. package/dist/chunk-VOAKEOIM.mjs.map +1 -0
  104. package/dist/function/index.mjs +3 -3
  105. package/dist/index.js.map +1 -1
  106. package/dist/index.mjs +67 -67
  107. package/dist/math/clamp.d.mts +1 -1
  108. package/dist/math/clamp.d.ts +1 -1
  109. package/dist/math/clamp.js.map +1 -1
  110. package/dist/math/clamp.mjs +1 -1
  111. package/dist/math/index.js.map +1 -1
  112. package/dist/math/index.mjs +3 -3
  113. package/dist/math/round.d.mts +1 -1
  114. package/dist/math/round.d.ts +1 -1
  115. package/dist/math/round.js.map +1 -1
  116. package/dist/math/round.mjs +1 -1
  117. package/dist/math/sum.d.mts +1 -1
  118. package/dist/math/sum.d.ts +1 -1
  119. package/dist/math/sum.js.map +1 -1
  120. package/dist/math/sum.mjs +1 -1
  121. package/dist/object/index.js.map +1 -1
  122. package/dist/object/index.mjs +4 -4
  123. package/dist/object/omit.d.mts +2 -2
  124. package/dist/object/omit.d.ts +2 -2
  125. package/dist/object/omit.js.map +1 -1
  126. package/dist/object/omit.mjs +1 -1
  127. package/dist/object/pick.d.mts +2 -2
  128. package/dist/object/pick.d.ts +2 -2
  129. package/dist/object/pick.js.map +1 -1
  130. package/dist/object/pick.mjs +1 -1
  131. package/dist/predicate/index.js.map +1 -1
  132. package/dist/predicate/index.mjs +3 -3
  133. package/dist/predicate/isNil.d.mts +1 -1
  134. package/dist/predicate/isNil.d.ts +1 -1
  135. package/dist/predicate/isNil.js.map +1 -1
  136. package/dist/predicate/isNil.mjs +1 -1
  137. package/dist/predicate/isNull.d.mts +1 -1
  138. package/dist/predicate/isNull.d.ts +1 -1
  139. package/dist/predicate/isNull.js.map +1 -1
  140. package/dist/predicate/isNull.mjs +1 -1
  141. package/dist/predicate/isUndefined.d.mts +1 -1
  142. package/dist/predicate/isUndefined.d.ts +1 -1
  143. package/dist/predicate/isUndefined.js.map +1 -1
  144. package/dist/predicate/isUndefined.mjs +1 -1
  145. package/package.json +1 -1
  146. package/dist/chunk-4PNP6CKQ.mjs.map +0 -1
  147. package/dist/chunk-6LDIBBWQ.mjs.map +0 -1
  148. package/dist/chunk-B5P232BA.mjs.map +0 -1
  149. package/dist/chunk-J6SWM4X6.mjs.map +0 -1
  150. package/dist/chunk-JDMFIUGM.mjs.map +0 -1
  151. package/dist/chunk-PRTIPC5X.mjs.map +0 -1
  152. package/dist/chunk-RK6PRCEJ.mjs.map +0 -1
  153. package/dist/chunk-SPLO5OZW.mjs.map +0 -1
  154. package/dist/chunk-SQOYF647.mjs.map +0 -1
  155. package/dist/chunk-TK2EDHSP.mjs.map +0 -1
  156. package/dist/chunk-YHY2XTJW.mjs.map +0 -1
  157. /package/dist/{chunk-VKVA56XG.mjs.map → chunk-3GMXDQQQ.mjs.map} +0 -0
  158. /package/dist/{chunk-YEZIGQJG.mjs.map → chunk-AB3DGGY3.mjs.map} +0 -0
  159. /package/dist/{chunk-GLAZTR32.mjs.map → chunk-I2NAKQIE.mjs.map} +0 -0
  160. /package/dist/{chunk-TCHT4HCP.mjs.map → chunk-S3ZF7ZPG.mjs.map} +0 -0
package/dist/index.mjs CHANGED
@@ -2,69 +2,80 @@ import "./chunk-ARZ5BDR6.mjs";
2
2
  import {
3
3
  delay
4
4
  } from "./chunk-ZBG3EYM3.mjs";
5
- import "./chunk-IJLQVGW4.mjs";
5
+ import "./chunk-T5JCRGXA.mjs";
6
6
  import {
7
- clamp
8
- } from "./chunk-RK6PRCEJ.mjs";
7
+ omit
8
+ } from "./chunk-PLTO44KM.mjs";
9
9
  import {
10
- round
11
- } from "./chunk-YHY2XTJW.mjs";
10
+ omitBy
11
+ } from "./chunk-SF3V7XXM.mjs";
12
12
  import {
13
- sum
14
- } from "./chunk-B5P232BA.mjs";
13
+ pick
14
+ } from "./chunk-OFWKFUFZ.mjs";
15
+ import {
16
+ pickBy
17
+ } from "./chunk-T2C2WVFL.mjs";
15
18
  import "./chunk-MAJSPFA6.mjs";
16
19
  import {
17
20
  isNotNil
18
21
  } from "./chunk-ZQNAZPSK.mjs";
19
22
  import {
20
23
  isNull
21
- } from "./chunk-Y6ZRNII6.mjs";
24
+ } from "./chunk-AIRSKN47.mjs";
22
25
  import {
23
26
  isUndefined
24
- } from "./chunk-HOQRMBSB.mjs";
27
+ } from "./chunk-VH2PV426.mjs";
25
28
  import {
26
29
  isNil
27
- } from "./chunk-KBJTBR5T.mjs";
28
- import "./chunk-EJGAXTF7.mjs";
30
+ } from "./chunk-OHQAR5AU.mjs";
31
+ import "./chunk-IJLQVGW4.mjs";
29
32
  import {
30
- zip
31
- } from "./chunk-L25VRQ54.mjs";
33
+ clamp
34
+ } from "./chunk-MLCL773E.mjs";
32
35
  import {
33
- zipWith
34
- } from "./chunk-PRTIPC5X.mjs";
36
+ round
37
+ } from "./chunk-V7E5DGZP.mjs";
38
+ import {
39
+ sum
40
+ } from "./chunk-7OU22ENP.mjs";
41
+ import "./chunk-N6EM6ETS.mjs";
42
+ import {
43
+ throttle
44
+ } from "./chunk-XLO3QZVY.mjs";
45
+ import {
46
+ debounce
47
+ } from "./chunk-GELVVASW.mjs";
48
+ import {
49
+ noop
50
+ } from "./chunk-LKXCOLNY.mjs";
51
+ import {
52
+ once
53
+ } from "./chunk-UFAA5WKR.mjs";
54
+ import "./chunk-EJGAXTF7.mjs";
35
55
  import {
36
56
  uniqBy
37
- } from "./chunk-TK2EDHSP.mjs";
57
+ } from "./chunk-JD42XAYW.mjs";
38
58
  import {
39
59
  xor
40
- } from "./chunk-VKVA56XG.mjs";
60
+ } from "./chunk-3GMXDQQQ.mjs";
41
61
  import {
42
62
  xorBy
43
- } from "./chunk-4PNP6CKQ.mjs";
44
- import {
45
- unionBy
46
- } from "./chunk-SPLO5OZW.mjs";
63
+ } from "./chunk-MTT7OPUK.mjs";
47
64
  import {
48
65
  xorWith
49
- } from "./chunk-TCHT4HCP.mjs";
50
- import {
51
- unionWith
52
- } from "./chunk-YEZIGQJG.mjs";
53
- import {
54
- uniqWith
55
- } from "./chunk-SQOYF647.mjs";
66
+ } from "./chunk-S3ZF7ZPG.mjs";
56
67
  import {
57
- partition
58
- } from "./chunk-TF6N37OE.mjs";
68
+ zip
69
+ } from "./chunk-L25VRQ54.mjs";
59
70
  import {
60
- sample
61
- } from "./chunk-PHG5JCSW.mjs";
71
+ zipWith
72
+ } from "./chunk-C4IZ7TGA.mjs";
62
73
  import {
63
74
  shuffle
64
75
  } from "./chunk-KPG3XQEN.mjs";
65
76
  import {
66
77
  take
67
- } from "./chunk-OLBUAFBX.mjs";
78
+ } from "./chunk-4RRRH7OY.mjs";
68
79
  import {
69
80
  takeRight
70
81
  } from "./chunk-L3C6TG2V.mjs";
@@ -76,19 +87,19 @@ import {
76
87
  } from "./chunk-LLOAPSQ6.mjs";
77
88
  import {
78
89
  union
79
- } from "./chunk-GLAZTR32.mjs";
90
+ } from "./chunk-I2NAKQIE.mjs";
80
91
  import {
81
92
  uniq
82
- } from "./chunk-JDMFIUGM.mjs";
93
+ } from "./chunk-SWPLMJR7.mjs";
83
94
  import {
84
- dropRight
85
- } from "./chunk-6GRNTXI3.mjs";
95
+ unionBy
96
+ } from "./chunk-LIXL7PEP.mjs";
86
97
  import {
87
- dropRightWhile
88
- } from "./chunk-6LDIBBWQ.mjs";
98
+ unionWith
99
+ } from "./chunk-AB3DGGY3.mjs";
89
100
  import {
90
- dropWhile
91
- } from "./chunk-3PFYAKOD.mjs";
101
+ uniqWith
102
+ } from "./chunk-DVRGUUQG.mjs";
92
103
  import {
93
104
  groupBy
94
105
  } from "./chunk-V6LXSPMF.mjs";
@@ -100,7 +111,13 @@ import {
100
111
  } from "./chunk-ANJSX6WH.mjs";
101
112
  import {
102
113
  intersectionWith
103
- } from "./chunk-7LAOIS6P.mjs";
114
+ } from "./chunk-6Z2YFKXQ.mjs";
115
+ import {
116
+ partition
117
+ } from "./chunk-TF6N37OE.mjs";
118
+ import {
119
+ sample
120
+ } from "./chunk-PHG5JCSW.mjs";
104
121
  import {
105
122
  chunk
106
123
  } from "./chunk-OS5PZ4B4.mjs";
@@ -112,36 +129,19 @@ import {
112
129
  } from "./chunk-HK5OJANS.mjs";
113
130
  import {
114
131
  differenceWith
115
- } from "./chunk-M3SHJ3LL.mjs";
132
+ } from "./chunk-5NSVMWDQ.mjs";
116
133
  import {
117
134
  drop
118
- } from "./chunk-6BCRFIEW.mjs";
119
- import "./chunk-N6EM6ETS.mjs";
120
- import {
121
- debounce
122
- } from "./chunk-GELVVASW.mjs";
135
+ } from "./chunk-25R2U4KM.mjs";
123
136
  import {
124
- noop
125
- } from "./chunk-LKXCOLNY.mjs";
126
- import {
127
- once
128
- } from "./chunk-UFAA5WKR.mjs";
129
- import {
130
- throttle
131
- } from "./chunk-XLO3QZVY.mjs";
132
- import "./chunk-T5JCRGXA.mjs";
133
- import {
134
- omitBy
135
- } from "./chunk-SF3V7XXM.mjs";
136
- import {
137
- pick
138
- } from "./chunk-AFYV2UVZ.mjs";
137
+ dropRight
138
+ } from "./chunk-EXU45QAF.mjs";
139
139
  import {
140
- pickBy
141
- } from "./chunk-T2C2WVFL.mjs";
140
+ dropRightWhile
141
+ } from "./chunk-VOAKEOIM.mjs";
142
142
  import {
143
- omit
144
- } from "./chunk-J6SWM4X6.mjs";
143
+ dropWhile
144
+ } from "./chunk-3PFYAKOD.mjs";
145
145
  import "./chunk-2MM5EJJX.mjs";
146
146
  export {
147
147
  chunk,
@@ -10,7 +10,7 @@
10
10
  * @returns {number} The clamped number within the specified bounds.
11
11
  *
12
12
  * @example
13
- * * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5
13
+ * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5
14
14
  * const result2 = clamp(10, 5, 15); // result2 will be 10, as it is within the bounds 5 and 15
15
15
  * const result3 = clamp(2, 5, 15); // result3 will be 5, as 2 is clamped to the lower bound 5
16
16
  * const result4 = clamp(20, 5, 15); // result4 will be 15, as 20 is clamped to the upper bound 15
@@ -10,7 +10,7 @@
10
10
  * @returns {number} The clamped number within the specified bounds.
11
11
  *
12
12
  * @example
13
- * * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5
13
+ * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5
14
14
  * const result2 = clamp(10, 5, 15); // result2 will be 10, as it is within the bounds 5 and 15
15
15
  * const result3 = clamp(2, 5, 15); // result3 will be 5, as 2 is clamped to the lower bound 5
16
16
  * const result4 = clamp(20, 5, 15); // result4 will be 15, as 20 is clamped to the upper bound 15
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/math/clamp.ts"],"sourcesContent":["/**\n * Clamps a number within the inclusive lower and upper bounds.\n *\n * This function takes a number and two bounds, and returns the number clamped within the specified bounds.\n * If only one bound is provided, it returns the minimum of the value and the bound.\n *\n * @param {number} value - The number to clamp.\n * @param {number} minimum - The minimum bound to clamp the number.\n * @param {number} maximum - The maximum bound to clamp the number.\n * @returns {number} The clamped number within the specified bounds.\n *\n * @example\n * * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5\n * const result2 = clamp(10, 5, 15); // result2 will be 10, as it is within the bounds 5 and 15\n * const result3 = clamp(2, 5, 15); // result3 will be 5, as 2 is clamped to the lower bound 5\n * const result4 = clamp(20, 5, 15); // result4 will be 15, as 20 is clamped to the upper bound 15\n */\nexport function clamp(value: number, maximum: number): number;\nexport function clamp(value: number, minimum: number, maximum: number): number;\nexport function clamp(value: number, bound1: number, bound2?: number): number {\n if (bound2 == null) {\n return Math.min(value, bound1);\n }\n\n return Math.min(Math.max(value, bound1), bound2);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAmBO,SAAS,MAAM,OAAe,QAAgB,QAAyB;AAC5E,MAAI,UAAU,MAAM;AAClB,WAAO,KAAK,IAAI,OAAO,MAAM;AAAA,EAC/B;AAEA,SAAO,KAAK,IAAI,KAAK,IAAI,OAAO,MAAM,GAAG,MAAM;AACjD;","names":[]}
1
+ {"version":3,"sources":["../../src/math/clamp.ts"],"sourcesContent":["/**\n * Clamps a number within the inclusive lower and upper bounds.\n *\n * This function takes a number and two bounds, and returns the number clamped within the specified bounds.\n * If only one bound is provided, it returns the minimum of the value and the bound.\n *\n * @param {number} value - The number to clamp.\n * @param {number} minimum - The minimum bound to clamp the number.\n * @param {number} maximum - The maximum bound to clamp the number.\n * @returns {number} The clamped number within the specified bounds.\n *\n * @example\n * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5\n * const result2 = clamp(10, 5, 15); // result2 will be 10, as it is within the bounds 5 and 15\n * const result3 = clamp(2, 5, 15); // result3 will be 5, as 2 is clamped to the lower bound 5\n * const result4 = clamp(20, 5, 15); // result4 will be 15, as 20 is clamped to the upper bound 15\n */\nexport function clamp(value: number, maximum: number): number;\nexport function clamp(value: number, minimum: number, maximum: number): number;\nexport function clamp(value: number, bound1: number, bound2?: number): number {\n if (bound2 == null) {\n return Math.min(value, bound1);\n }\n\n return Math.min(Math.max(value, bound1), bound2);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAmBO,SAAS,MAAM,OAAe,QAAgB,QAAyB;AAC5E,MAAI,UAAU,MAAM;AAClB,WAAO,KAAK,IAAI,OAAO,MAAM;AAAA,EAC/B;AAEA,SAAO,KAAK,IAAI,KAAK,IAAI,OAAO,MAAM,GAAG,MAAM;AACjD;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  clamp
3
- } from "../chunk-RK6PRCEJ.mjs";
3
+ } from "../chunk-MLCL773E.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  clamp
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/math/index.ts","../../src/math/clamp.ts","../../src/math/round.ts","../../src/math/sum.ts"],"sourcesContent":["export { clamp } from './clamp';\nexport { round } from './round';\nexport { sum } from './sum';\n","/**\n * Clamps a number within the inclusive lower and upper bounds.\n *\n * This function takes a number and two bounds, and returns the number clamped within the specified bounds.\n * If only one bound is provided, it returns the minimum of the value and the bound.\n *\n * @param {number} value - The number to clamp.\n * @param {number} minimum - The minimum bound to clamp the number.\n * @param {number} maximum - The maximum bound to clamp the number.\n * @returns {number} The clamped number within the specified bounds.\n *\n * @example\n * * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5\n * const result2 = clamp(10, 5, 15); // result2 will be 10, as it is within the bounds 5 and 15\n * const result3 = clamp(2, 5, 15); // result3 will be 5, as 2 is clamped to the lower bound 5\n * const result4 = clamp(20, 5, 15); // result4 will be 15, as 20 is clamped to the upper bound 15\n */\nexport function clamp(value: number, maximum: number): number;\nexport function clamp(value: number, minimum: number, maximum: number): number;\nexport function clamp(value: number, bound1: number, bound2?: number): number {\n if (bound2 == null) {\n return Math.min(value, bound1);\n }\n\n return Math.min(Math.max(value, bound1), bound2);\n}\n","/**\n * Rounds a number to a specified precision.\n *\n * This function takes a number and an optional precision value, and returns the number rounded\n * to the specified number of decimal places.\n *\n * @param {number} value - The number to round.\n * @param {number} [precision=0] - The number of decimal places to round to. Defaults to 0.\n * @returns {number} The rounded number.\n *\n * @example\n * * const result1 = round(1.2345); // result1 will be 1\n * const result2 = round(1.2345, 2); // result2 will be 1.23\n * const result3 = round(1.2345, 3); // result3 will be 1.235\n */\nexport function round(value: number, precision: number = 0): number {\n const multiplier = Math.pow(10, precision);\n return Math.round(value * multiplier) / multiplier;\n}\n","/**\n * Calculates the sum of an array of numbers.\n *\n * This function takes an array of numbers and returns the sum of all the elements in the array.\n *\n * @param {number[]} nums - An array of numbers to be summed.\n * @returns {number} The sum of all the numbers in the array.\n *\n * @example\n * * const numbers = [1, 2, 3, 4, 5];\n * const result = sum(numbers);\n * // result will be 15\n */\nexport function sum(nums: number[]): number {\n let result = 0;\n\n for (const num of nums) {\n result += num;\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACmBO,SAAS,MAAM,OAAe,QAAgB,QAAyB;AAC5E,MAAI,UAAU,MAAM;AAClB,WAAO,KAAK,IAAI,OAAO,MAAM;AAAA,EAC/B;AAEA,SAAO,KAAK,IAAI,KAAK,IAAI,OAAO,MAAM,GAAG,MAAM;AACjD;;;ACVO,SAAS,MAAM,OAAe,YAAoB,GAAW;AAClE,QAAM,aAAa,KAAK,IAAI,IAAI,SAAS;AACzC,SAAO,KAAK,MAAM,QAAQ,UAAU,IAAI;AAC1C;;;ACLO,SAAS,IAAI,MAAwB;AAC1C,MAAI,SAAS;AAEb,aAAW,OAAO,MAAM;AACtB,cAAU;AAAA,EACZ;AAEA,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/math/index.ts","../../src/math/clamp.ts","../../src/math/round.ts","../../src/math/sum.ts"],"sourcesContent":["export { clamp } from './clamp';\nexport { round } from './round';\nexport { sum } from './sum';\n","/**\n * Clamps a number within the inclusive lower and upper bounds.\n *\n * This function takes a number and two bounds, and returns the number clamped within the specified bounds.\n * If only one bound is provided, it returns the minimum of the value and the bound.\n *\n * @param {number} value - The number to clamp.\n * @param {number} minimum - The minimum bound to clamp the number.\n * @param {number} maximum - The maximum bound to clamp the number.\n * @returns {number} The clamped number within the specified bounds.\n *\n * @example\n * const result1 = clamp(10, 5); // result1 will be 5, as 10 is clamped to the bound 5\n * const result2 = clamp(10, 5, 15); // result2 will be 10, as it is within the bounds 5 and 15\n * const result3 = clamp(2, 5, 15); // result3 will be 5, as 2 is clamped to the lower bound 5\n * const result4 = clamp(20, 5, 15); // result4 will be 15, as 20 is clamped to the upper bound 15\n */\nexport function clamp(value: number, maximum: number): number;\nexport function clamp(value: number, minimum: number, maximum: number): number;\nexport function clamp(value: number, bound1: number, bound2?: number): number {\n if (bound2 == null) {\n return Math.min(value, bound1);\n }\n\n return Math.min(Math.max(value, bound1), bound2);\n}\n","/**\n * Rounds a number to a specified precision.\n *\n * This function takes a number and an optional precision value, and returns the number rounded\n * to the specified number of decimal places.\n *\n * @param {number} value - The number to round.\n * @param {number} [precision=0] - The number of decimal places to round to. Defaults to 0.\n * @returns {number} The rounded number.\n *\n * @example\n * const result1 = round(1.2345); // result1 will be 1\n * const result2 = round(1.2345, 2); // result2 will be 1.23\n * const result3 = round(1.2345, 3); // result3 will be 1.235\n */\nexport function round(value: number, precision: number = 0): number {\n const multiplier = Math.pow(10, precision);\n return Math.round(value * multiplier) / multiplier;\n}\n","/**\n * Calculates the sum of an array of numbers.\n *\n * This function takes an array of numbers and returns the sum of all the elements in the array.\n *\n * @param {number[]} nums - An array of numbers to be summed.\n * @returns {number} The sum of all the numbers in the array.\n *\n * @example\n * const numbers = [1, 2, 3, 4, 5];\n * const result = sum(numbers);\n * // result will be 15\n */\nexport function sum(nums: number[]): number {\n let result = 0;\n\n for (const num of nums) {\n result += num;\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACmBO,SAAS,MAAM,OAAe,QAAgB,QAAyB;AAC5E,MAAI,UAAU,MAAM;AAClB,WAAO,KAAK,IAAI,OAAO,MAAM;AAAA,EAC/B;AAEA,SAAO,KAAK,IAAI,KAAK,IAAI,OAAO,MAAM,GAAG,MAAM;AACjD;;;ACVO,SAAS,MAAM,OAAe,YAAoB,GAAW;AAClE,QAAM,aAAa,KAAK,IAAI,IAAI,SAAS;AACzC,SAAO,KAAK,MAAM,QAAQ,UAAU,IAAI;AAC1C;;;ACLO,SAAS,IAAI,MAAwB;AAC1C,MAAI,SAAS;AAEb,aAAW,OAAO,MAAM;AACtB,cAAU;AAAA,EACZ;AAEA,SAAO;AACT;","names":[]}
@@ -1,13 +1,13 @@
1
1
  import "../chunk-IJLQVGW4.mjs";
2
2
  import {
3
3
  clamp
4
- } from "../chunk-RK6PRCEJ.mjs";
4
+ } from "../chunk-MLCL773E.mjs";
5
5
  import {
6
6
  round
7
- } from "../chunk-YHY2XTJW.mjs";
7
+ } from "../chunk-V7E5DGZP.mjs";
8
8
  import {
9
9
  sum
10
- } from "../chunk-B5P232BA.mjs";
10
+ } from "../chunk-7OU22ENP.mjs";
11
11
  import "../chunk-2MM5EJJX.mjs";
12
12
  export {
13
13
  clamp,
@@ -9,7 +9,7 @@
9
9
  * @returns {number} The rounded number.
10
10
  *
11
11
  * @example
12
- * * const result1 = round(1.2345); // result1 will be 1
12
+ * const result1 = round(1.2345); // result1 will be 1
13
13
  * const result2 = round(1.2345, 2); // result2 will be 1.23
14
14
  * const result3 = round(1.2345, 3); // result3 will be 1.235
15
15
  */
@@ -9,7 +9,7 @@
9
9
  * @returns {number} The rounded number.
10
10
  *
11
11
  * @example
12
- * * const result1 = round(1.2345); // result1 will be 1
12
+ * const result1 = round(1.2345); // result1 will be 1
13
13
  * const result2 = round(1.2345, 2); // result2 will be 1.23
14
14
  * const result3 = round(1.2345, 3); // result3 will be 1.235
15
15
  */
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/math/round.ts"],"sourcesContent":["/**\n * Rounds a number to a specified precision.\n *\n * This function takes a number and an optional precision value, and returns the number rounded\n * to the specified number of decimal places.\n *\n * @param {number} value - The number to round.\n * @param {number} [precision=0] - The number of decimal places to round to. Defaults to 0.\n * @returns {number} The rounded number.\n *\n * @example\n * * const result1 = round(1.2345); // result1 will be 1\n * const result2 = round(1.2345, 2); // result2 will be 1.23\n * const result3 = round(1.2345, 3); // result3 will be 1.235\n */\nexport function round(value: number, precision: number = 0): number {\n const multiplier = Math.pow(10, precision);\n return Math.round(value * multiplier) / multiplier;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeO,SAAS,MAAM,OAAe,YAAoB,GAAW;AAClE,QAAM,aAAa,KAAK,IAAI,IAAI,SAAS;AACzC,SAAO,KAAK,MAAM,QAAQ,UAAU,IAAI;AAC1C;","names":[]}
1
+ {"version":3,"sources":["../../src/math/round.ts"],"sourcesContent":["/**\n * Rounds a number to a specified precision.\n *\n * This function takes a number and an optional precision value, and returns the number rounded\n * to the specified number of decimal places.\n *\n * @param {number} value - The number to round.\n * @param {number} [precision=0] - The number of decimal places to round to. Defaults to 0.\n * @returns {number} The rounded number.\n *\n * @example\n * const result1 = round(1.2345); // result1 will be 1\n * const result2 = round(1.2345, 2); // result2 will be 1.23\n * const result3 = round(1.2345, 3); // result3 will be 1.235\n */\nexport function round(value: number, precision: number = 0): number {\n const multiplier = Math.pow(10, precision);\n return Math.round(value * multiplier) / multiplier;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeO,SAAS,MAAM,OAAe,YAAoB,GAAW;AAClE,QAAM,aAAa,KAAK,IAAI,IAAI,SAAS;AACzC,SAAO,KAAK,MAAM,QAAQ,UAAU,IAAI;AAC1C;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  round
3
- } from "../chunk-YHY2XTJW.mjs";
3
+ } from "../chunk-V7E5DGZP.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  round
@@ -7,7 +7,7 @@
7
7
  * @returns {number} The sum of all the numbers in the array.
8
8
  *
9
9
  * @example
10
- * * const numbers = [1, 2, 3, 4, 5];
10
+ * const numbers = [1, 2, 3, 4, 5];
11
11
  * const result = sum(numbers);
12
12
  * // result will be 15
13
13
  */
@@ -7,7 +7,7 @@
7
7
  * @returns {number} The sum of all the numbers in the array.
8
8
  *
9
9
  * @example
10
- * * const numbers = [1, 2, 3, 4, 5];
10
+ * const numbers = [1, 2, 3, 4, 5];
11
11
  * const result = sum(numbers);
12
12
  * // result will be 15
13
13
  */
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/math/sum.ts"],"sourcesContent":["/**\n * Calculates the sum of an array of numbers.\n *\n * This function takes an array of numbers and returns the sum of all the elements in the array.\n *\n * @param {number[]} nums - An array of numbers to be summed.\n * @returns {number} The sum of all the numbers in the array.\n *\n * @example\n * * const numbers = [1, 2, 3, 4, 5];\n * const result = sum(numbers);\n * // result will be 15\n */\nexport function sum(nums: number[]): number {\n let result = 0;\n\n for (const num of nums) {\n result += num;\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAaO,SAAS,IAAI,MAAwB;AAC1C,MAAI,SAAS;AAEb,aAAW,OAAO,MAAM;AACtB,cAAU;AAAA,EACZ;AAEA,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/math/sum.ts"],"sourcesContent":["/**\n * Calculates the sum of an array of numbers.\n *\n * This function takes an array of numbers and returns the sum of all the elements in the array.\n *\n * @param {number[]} nums - An array of numbers to be summed.\n * @returns {number} The sum of all the numbers in the array.\n *\n * @example\n * const numbers = [1, 2, 3, 4, 5];\n * const result = sum(numbers);\n * // result will be 15\n */\nexport function sum(nums: number[]): number {\n let result = 0;\n\n for (const num of nums) {\n result += num;\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAaO,SAAS,IAAI,MAAwB;AAC1C,MAAI,SAAS;AAEb,aAAW,OAAO,MAAM;AACtB,cAAU;AAAA,EACZ;AAEA,SAAO;AACT;","names":[]}
package/dist/math/sum.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  sum
3
- } from "../chunk-B5P232BA.mjs";
3
+ } from "../chunk-7OU22ENP.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  sum
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/object/index.ts","../../src/object/omit.ts","../../src/object/omitBy.ts","../../src/object/pick.ts","../../src/object/pickBy.ts"],"sourcesContent":["export { omit } from './omit';\nexport { omitBy } from './omitBy';\nexport { pick } from './pick';\nexport { pickBy } from './pickBy';\n","/**\n * Creates a new object with specified keys omitted.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * excludes the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to omit keys from.\n * @param {K[]} keys - An array of keys to be omitted from the object.\n * @returns {Omit<T, K>} A new object with the specified keys omitted.\n *\n * @example\n * * const obj = { a: 1, b: 2, c: 3 };\n * const result = omit(obj, ['b', 'c']);\n * // result will be { a: 1 }\n */\nexport function omit<T, K extends keyof T>(obj: T, keys: K[]): Omit<T, K> {\n const result = { ...obj };\n\n for (const key of keys) {\n delete result[key];\n }\n\n return result as Omit<T, K>;\n}\n","/**\n * Creates a new object composed of the properties that do not satisfy the predicate function.\n *\n * This function takes an object and a predicate function, and returns a new object that\n * includes only the properties for which the predicate function returns false.\n *\n * @param {T} obj - The object to omit properties from.\n * @param {(value: T[string], key: string) => boolean} shouldOmit - A predicate function that determines\n * whether a property should be omitted. It takes the property's key and value as arguments and returns `true`\n * if the property should be omitted, and `false` otherwise.\n * @returns {Partial<T>} A new object with the properties that do not satisfy the predicate function.\n *\n * @example\n * const obj = { a: 1, b: 'omit', c: 3 };\n * const shouldOmit = (key, value) => typeof value === 'string';\n * const result = omitBy(obj, shouldOmit);\n * // result will be { a: 1, c: 3 }\n */\nexport function omitBy<T extends Record<string, any>>(\n obj: T,\n shouldOmit: (value: T[keyof T], key: string) => boolean\n): Partial<T> {\n const result: Partial<T> = {};\n\n for (const [key, value] of Object.entries(obj)) {\n if (shouldOmit(value, key)) {\n continue;\n }\n\n (result as any)[key] = value;\n }\n\n return result;\n}\n","/**\n * Creates a new object composed of the picked object properties.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * includes only the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to pick keys from.\n * @param {K[]} keys - An array of keys to be picked from the object.\n * @returns {Pick<T, K>} A new object with the specified keys picked.\n *\n * @example\n * * const obj = { a: 1, b: 2, c: 3 };\n * const result = pick(obj, ['a', 'c']);\n * // result will be { a: 1, c: 3 }\n */\nexport function pick<T, K extends keyof T>(obj: T, keys: K[]): Pick<T, K> {\n const result = {} as Pick<T, K>;\n\n for (const key of keys) {\n result[key] = obj[key];\n }\n\n return result;\n}\n","/**\n * Creates a new object composed of the properties that satisfy the predicate function.\n *\n * This function takes an object and a predicate function, and returns a new object that\n * includes only the properties for which the predicate function returns true.\n *\n * @param {T} obj - The object to pick properties from.\n * @param {(value: T[keyof T], key: string) => boolean} shouldPick - A predicate function that determines\n * whether a property should be picked. It takes the property's key and value as arguments and returns `true`\n * if the property should be picked, and `false` otherwise.\n * @returns {Partial<T>} A new object with the properties that satisfy the predicate function.\n *\n * @example\n * const obj = { a: 1, b: 'pick', c: 3 };\n * const shouldPick = (value) => typeof value === 'string';\n * const result = pickBy(obj, shouldPick);\n * // result will be { b: 'pick' }\n */\nexport function pickBy<T extends Record<string, any>>(\n obj: T,\n shouldPick: (value: T[keyof T], key: string) => boolean\n): Partial<T> {\n const result: Partial<T> = {};\n\n for (const [key, value] of Object.entries(obj)) {\n if (!shouldPick(value, key)) {\n continue;\n }\n\n (result as any)[key] = value;\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACeO,SAAS,KAA2B,KAAQ,MAAuB;AACxE,QAAM,SAAS,mBAAK;AAEpB,aAAW,OAAO,MAAM;AACtB,WAAO,OAAO,GAAG;AAAA,EACnB;AAEA,SAAO;AACT;;;ACLO,SAAS,OACd,KACA,YACY;AACZ,QAAM,SAAqB,CAAC;AAE5B,aAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,GAAG,GAAG;AAC9C,QAAI,WAAW,OAAO,GAAG,GAAG;AAC1B;AAAA,IACF;AAEA,IAAC,OAAe,GAAG,IAAI;AAAA,EACzB;AAEA,SAAO;AACT;;;AClBO,SAAS,KAA2B,KAAQ,MAAuB;AACxE,QAAM,SAAS,CAAC;AAEhB,aAAW,OAAO,MAAM;AACtB,WAAO,GAAG,IAAI,IAAI,GAAG;AAAA,EACvB;AAEA,SAAO;AACT;;;ACLO,SAAS,OACd,KACA,YACY;AACZ,QAAM,SAAqB,CAAC;AAE5B,aAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,GAAG,GAAG;AAC9C,QAAI,CAAC,WAAW,OAAO,GAAG,GAAG;AAC3B;AAAA,IACF;AAEA,IAAC,OAAe,GAAG,IAAI;AAAA,EACzB;AAEA,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/object/index.ts","../../src/object/omit.ts","../../src/object/omitBy.ts","../../src/object/pick.ts","../../src/object/pickBy.ts"],"sourcesContent":["export { omit } from './omit';\nexport { omitBy } from './omitBy';\nexport { pick } from './pick';\nexport { pickBy } from './pickBy';\n","/**\n * Creates a new object with specified keys omitted.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * excludes the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to omit keys from.\n * @param {K[]} keys - An array of keys to be omitted from the object.\n * @returns {Omit<T, K>} A new object with the specified keys omitted.\n *\n * @example\n * const obj = { a: 1, b: 2, c: 3 };\n * const result = omit(obj, ['b', 'c']);\n * // result will be { a: 1 }\n */\nexport function omit<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Omit<T, K> {\n const result = { ...obj };\n\n for (const key of keys) {\n delete result[key];\n }\n\n return result as Omit<T, K>;\n}\n","/**\n * Creates a new object composed of the properties that do not satisfy the predicate function.\n *\n * This function takes an object and a predicate function, and returns a new object that\n * includes only the properties for which the predicate function returns false.\n *\n * @param {T} obj - The object to omit properties from.\n * @param {(value: T[string], key: string) => boolean} shouldOmit - A predicate function that determines\n * whether a property should be omitted. It takes the property's key and value as arguments and returns `true`\n * if the property should be omitted, and `false` otherwise.\n * @returns {Partial<T>} A new object with the properties that do not satisfy the predicate function.\n *\n * @example\n * const obj = { a: 1, b: 'omit', c: 3 };\n * const shouldOmit = (key, value) => typeof value === 'string';\n * const result = omitBy(obj, shouldOmit);\n * // result will be { a: 1, c: 3 }\n */\nexport function omitBy<T extends Record<string, any>>(\n obj: T,\n shouldOmit: (value: T[keyof T], key: string) => boolean\n): Partial<T> {\n const result: Partial<T> = {};\n\n for (const [key, value] of Object.entries(obj)) {\n if (shouldOmit(value, key)) {\n continue;\n }\n\n (result as any)[key] = value;\n }\n\n return result;\n}\n","/**\n * Creates a new object composed of the picked object properties.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * includes only the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to pick keys from.\n * @param {K[]} keys - An array of keys to be picked from the object.\n * @returns {Pick<T, K>} A new object with the specified keys picked.\n *\n * @example\n * const obj = { a: 1, b: 2, c: 3 };\n * const result = pick(obj, ['a', 'c']);\n * // result will be { a: 1, c: 3 }\n */\nexport function pick<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Pick<T, K> {\n const result = {} as Pick<T, K>;\n\n for (const key of keys) {\n result[key] = obj[key];\n }\n\n return result;\n}\n","/**\n * Creates a new object composed of the properties that satisfy the predicate function.\n *\n * This function takes an object and a predicate function, and returns a new object that\n * includes only the properties for which the predicate function returns true.\n *\n * @param {T} obj - The object to pick properties from.\n * @param {(value: T[keyof T], key: string) => boolean} shouldPick - A predicate function that determines\n * whether a property should be picked. It takes the property's key and value as arguments and returns `true`\n * if the property should be picked, and `false` otherwise.\n * @returns {Partial<T>} A new object with the properties that satisfy the predicate function.\n *\n * @example\n * const obj = { a: 1, b: 'pick', c: 3 };\n * const shouldPick = (value) => typeof value === 'string';\n * const result = pickBy(obj, shouldPick);\n * // result will be { b: 'pick' }\n */\nexport function pickBy<T extends Record<string, any>>(\n obj: T,\n shouldPick: (value: T[keyof T], key: string) => boolean\n): Partial<T> {\n const result: Partial<T> = {};\n\n for (const [key, value] of Object.entries(obj)) {\n if (!shouldPick(value, key)) {\n continue;\n }\n\n (result as any)[key] = value;\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACeO,SAAS,KAAuD,KAAQ,MAAuB;AACpG,QAAM,SAAS,mBAAK;AAEpB,aAAW,OAAO,MAAM;AACtB,WAAO,OAAO,GAAG;AAAA,EACnB;AAEA,SAAO;AACT;;;ACLO,SAAS,OACd,KACA,YACY;AACZ,QAAM,SAAqB,CAAC;AAE5B,aAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,GAAG,GAAG;AAC9C,QAAI,WAAW,OAAO,GAAG,GAAG;AAC1B;AAAA,IACF;AAEA,IAAC,OAAe,GAAG,IAAI;AAAA,EACzB;AAEA,SAAO;AACT;;;AClBO,SAAS,KAAuD,KAAQ,MAAuB;AACpG,QAAM,SAAS,CAAC;AAEhB,aAAW,OAAO,MAAM;AACtB,WAAO,GAAG,IAAI,IAAI,GAAG;AAAA,EACvB;AAEA,SAAO;AACT;;;ACLO,SAAS,OACd,KACA,YACY;AACZ,QAAM,SAAqB,CAAC;AAE5B,aAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,GAAG,GAAG;AAC9C,QAAI,CAAC,WAAW,OAAO,GAAG,GAAG;AAC3B;AAAA,IACF;AAEA,IAAC,OAAe,GAAG,IAAI;AAAA,EACzB;AAEA,SAAO;AACT;","names":[]}
@@ -1,16 +1,16 @@
1
1
  import "../chunk-T5JCRGXA.mjs";
2
+ import {
3
+ omit
4
+ } from "../chunk-PLTO44KM.mjs";
2
5
  import {
3
6
  omitBy
4
7
  } from "../chunk-SF3V7XXM.mjs";
5
8
  import {
6
9
  pick
7
- } from "../chunk-AFYV2UVZ.mjs";
10
+ } from "../chunk-OFWKFUFZ.mjs";
8
11
  import {
9
12
  pickBy
10
13
  } from "../chunk-T2C2WVFL.mjs";
11
- import {
12
- omit
13
- } from "../chunk-J6SWM4X6.mjs";
14
14
  import "../chunk-2MM5EJJX.mjs";
15
15
  export {
16
16
  omit,
@@ -9,10 +9,10 @@
9
9
  * @returns {Omit<T, K>} A new object with the specified keys omitted.
10
10
  *
11
11
  * @example
12
- * * const obj = { a: 1, b: 2, c: 3 };
12
+ * const obj = { a: 1, b: 2, c: 3 };
13
13
  * const result = omit(obj, ['b', 'c']);
14
14
  * // result will be { a: 1 }
15
15
  */
16
- declare function omit<T, K extends keyof T>(obj: T, keys: K[]): Omit<T, K>;
16
+ declare function omit<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Omit<T, K>;
17
17
 
18
18
  export { omit };
@@ -9,10 +9,10 @@
9
9
  * @returns {Omit<T, K>} A new object with the specified keys omitted.
10
10
  *
11
11
  * @example
12
- * * const obj = { a: 1, b: 2, c: 3 };
12
+ * const obj = { a: 1, b: 2, c: 3 };
13
13
  * const result = omit(obj, ['b', 'c']);
14
14
  * // result will be { a: 1 }
15
15
  */
16
- declare function omit<T, K extends keyof T>(obj: T, keys: K[]): Omit<T, K>;
16
+ declare function omit<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Omit<T, K>;
17
17
 
18
18
  export { omit };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/object/omit.ts"],"sourcesContent":["/**\n * Creates a new object with specified keys omitted.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * excludes the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to omit keys from.\n * @param {K[]} keys - An array of keys to be omitted from the object.\n * @returns {Omit<T, K>} A new object with the specified keys omitted.\n *\n * @example\n * * const obj = { a: 1, b: 2, c: 3 };\n * const result = omit(obj, ['b', 'c']);\n * // result will be { a: 1 }\n */\nexport function omit<T, K extends keyof T>(obj: T, keys: K[]): Omit<T, K> {\n const result = { ...obj };\n\n for (const key of keys) {\n delete result[key];\n }\n\n return result as Omit<T, K>;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeO,SAAS,KAA2B,KAAQ,MAAuB;AACxE,QAAM,SAAS,mBAAK;AAEpB,aAAW,OAAO,MAAM;AACtB,WAAO,OAAO,GAAG;AAAA,EACnB;AAEA,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/object/omit.ts"],"sourcesContent":["/**\n * Creates a new object with specified keys omitted.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * excludes the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to omit keys from.\n * @param {K[]} keys - An array of keys to be omitted from the object.\n * @returns {Omit<T, K>} A new object with the specified keys omitted.\n *\n * @example\n * const obj = { a: 1, b: 2, c: 3 };\n * const result = omit(obj, ['b', 'c']);\n * // result will be { a: 1 }\n */\nexport function omit<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Omit<T, K> {\n const result = { ...obj };\n\n for (const key of keys) {\n delete result[key];\n }\n\n return result as Omit<T, K>;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeO,SAAS,KAAuD,KAAQ,MAAuB;AACpG,QAAM,SAAS,mBAAK;AAEpB,aAAW,OAAO,MAAM;AACtB,WAAO,OAAO,GAAG;AAAA,EACnB;AAEA,SAAO;AACT;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  omit
3
- } from "../chunk-J6SWM4X6.mjs";
3
+ } from "../chunk-PLTO44KM.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  omit
@@ -9,10 +9,10 @@
9
9
  * @returns {Pick<T, K>} A new object with the specified keys picked.
10
10
  *
11
11
  * @example
12
- * * const obj = { a: 1, b: 2, c: 3 };
12
+ * const obj = { a: 1, b: 2, c: 3 };
13
13
  * const result = pick(obj, ['a', 'c']);
14
14
  * // result will be { a: 1, c: 3 }
15
15
  */
16
- declare function pick<T, K extends keyof T>(obj: T, keys: K[]): Pick<T, K>;
16
+ declare function pick<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Pick<T, K>;
17
17
 
18
18
  export { pick };
@@ -9,10 +9,10 @@
9
9
  * @returns {Pick<T, K>} A new object with the specified keys picked.
10
10
  *
11
11
  * @example
12
- * * const obj = { a: 1, b: 2, c: 3 };
12
+ * const obj = { a: 1, b: 2, c: 3 };
13
13
  * const result = pick(obj, ['a', 'c']);
14
14
  * // result will be { a: 1, c: 3 }
15
15
  */
16
- declare function pick<T, K extends keyof T>(obj: T, keys: K[]): Pick<T, K>;
16
+ declare function pick<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Pick<T, K>;
17
17
 
18
18
  export { pick };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/object/pick.ts"],"sourcesContent":["/**\n * Creates a new object composed of the picked object properties.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * includes only the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to pick keys from.\n * @param {K[]} keys - An array of keys to be picked from the object.\n * @returns {Pick<T, K>} A new object with the specified keys picked.\n *\n * @example\n * * const obj = { a: 1, b: 2, c: 3 };\n * const result = pick(obj, ['a', 'c']);\n * // result will be { a: 1, c: 3 }\n */\nexport function pick<T, K extends keyof T>(obj: T, keys: K[]): Pick<T, K> {\n const result = {} as Pick<T, K>;\n\n for (const key of keys) {\n result[key] = obj[key];\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeO,SAAS,KAA2B,KAAQ,MAAuB;AACxE,QAAM,SAAS,CAAC;AAEhB,aAAW,OAAO,MAAM;AACtB,WAAO,GAAG,IAAI,IAAI,GAAG;AAAA,EACvB;AAEA,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/object/pick.ts"],"sourcesContent":["/**\n * Creates a new object composed of the picked object properties.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * includes only the properties corresponding to the specified keys.\n *\n * @param {T} obj - The object to pick keys from.\n * @param {K[]} keys - An array of keys to be picked from the object.\n * @returns {Pick<T, K>} A new object with the specified keys picked.\n *\n * @example\n * const obj = { a: 1, b: 2, c: 3 };\n * const result = pick(obj, ['a', 'c']);\n * // result will be { a: 1, c: 3 }\n */\nexport function pick<T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Pick<T, K> {\n const result = {} as Pick<T, K>;\n\n for (const key of keys) {\n result[key] = obj[key];\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeO,SAAS,KAAuD,KAAQ,MAAuB;AACpG,QAAM,SAAS,CAAC;AAEhB,aAAW,OAAO,MAAM;AACtB,WAAO,GAAG,IAAI,IAAI,GAAG;AAAA,EACvB;AAEA,SAAO;AACT;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  pick
3
- } from "../chunk-AFYV2UVZ.mjs";
3
+ } from "../chunk-OFWKFUFZ.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  pick
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/predicate/index.ts","../../src/predicate/isNil.ts","../../src/predicate/isNotNil.ts","../../src/predicate/isNull.ts","../../src/predicate/isUndefined.ts"],"sourcesContent":["export { isNil } from './isNil';\nexport { isNotNil } from './isNotNil';\nexport { isNull } from './isNull';\nexport { isUndefined } from './isUndefined';\n","/**\n * Checks if a given value is null or undefined.\n *\n * This function tests whether the provided value is either `null` or `undefined`.\n * It returns `true` if the value is `null` or `undefined`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null` or `undefined`.\n *\n * @param {unknown} x - The value to test for null or undefined.\n * @returns {boolean} `true` if the value is null or undefined, `false` otherwise.\n *\n * @example\n * * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n * const result1 = isNil(value1); // true\n * const result2 = isNil(value2); // true\n * const result3 = isNil(value3); // false\n */\nexport function isNil(x: unknown): x is null | undefined {\n return x === null || x === undefined;\n}\n","/**\n * Checks if the given value is not null nor undefined.\n *\n * The main use of this function is to be used with TypeScript as a type predicate.\n *\n * @param {T | null | undefined} x - The value to test if it is not null nor undefined.\n * @returns {x is T} True if the value is not null nor undefined, false otherwise.\n *\n * @example\n * // Here the type of `arr` is (number | undefined)[]\n * const arr = [1, undefined, 3];\n * // Here the type of `result` is number[]\n * const result = arr.filter(isNotNil);\n * // result will be [1, 3]\n */\nexport function isNotNil<T>(x: T | null | undefined): x is T {\n return x !== null && x !== undefined;\n}\n","/**\n * Checks if the given value is null.\n *\n * This function tests whether the provided value is strictly equal to `null`.\n * It returns `true` if the value is `null`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null`.\n *\n * @param {unknown} x - The value to test if it is null.\n * @returns {x is null} True if the value is null, false otherwise.\n *\n * @example\n * * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n *\n * console.log(isNull(value1)); // true\n * console.log(isNull(value2)); // false\n * console.log(isNull(value3)); // false\n */\nexport function isNull(x: unknown): x is null {\n return x === null;\n}\n","/**\n * Checks if the given value is undefined.\n *\n * This function tests whether the provided value is strictly equal to `undefined`.\n * It returns `true` if the value is `undefined`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `undefined`.\n *\n * @param {unknown} x - The value to test if it is undefined.\n * @returns {x is undefined} true if the value is undefined, false otherwise.\n *\n * @example\n * * const value1 = undefined;\n * const value2 = null;\n * const value3 = 42;\n *\n * console.log(isUndefined(value1)); // true\n * console.log(isUndefined(value2)); // false\n * console.log(isUndefined(value3)); // false\n */\nexport function isUndefined(x: unknown): x is undefined {\n return x === undefined;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACmBO,SAAS,MAAM,GAAmC;AACvD,SAAO,MAAM,QAAQ,MAAM;AAC7B;;;ACNO,SAAS,SAAY,GAAiC;AAC3D,SAAO,MAAM,QAAQ,MAAM;AAC7B;;;ACGO,SAAS,OAAO,GAAuB;AAC5C,SAAO,MAAM;AACf;;;ACFO,SAAS,YAAY,GAA4B;AACtD,SAAO,MAAM;AACf;","names":[]}
1
+ {"version":3,"sources":["../../src/predicate/index.ts","../../src/predicate/isNil.ts","../../src/predicate/isNotNil.ts","../../src/predicate/isNull.ts","../../src/predicate/isUndefined.ts"],"sourcesContent":["export { isNil } from './isNil';\nexport { isNotNil } from './isNotNil';\nexport { isNull } from './isNull';\nexport { isUndefined } from './isUndefined';\n","/**\n * Checks if a given value is null or undefined.\n *\n * This function tests whether the provided value is either `null` or `undefined`.\n * It returns `true` if the value is `null` or `undefined`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null` or `undefined`.\n *\n * @param {unknown} x - The value to test for null or undefined.\n * @returns {boolean} `true` if the value is null or undefined, `false` otherwise.\n *\n * @example\n * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n * const result1 = isNil(value1); // true\n * const result2 = isNil(value2); // true\n * const result3 = isNil(value3); // false\n */\nexport function isNil(x: unknown): x is null | undefined {\n return x === null || x === undefined;\n}\n","/**\n * Checks if the given value is not null nor undefined.\n *\n * The main use of this function is to be used with TypeScript as a type predicate.\n *\n * @param {T | null | undefined} x - The value to test if it is not null nor undefined.\n * @returns {x is T} True if the value is not null nor undefined, false otherwise.\n *\n * @example\n * // Here the type of `arr` is (number | undefined)[]\n * const arr = [1, undefined, 3];\n * // Here the type of `result` is number[]\n * const result = arr.filter(isNotNil);\n * // result will be [1, 3]\n */\nexport function isNotNil<T>(x: T | null | undefined): x is T {\n return x !== null && x !== undefined;\n}\n","/**\n * Checks if the given value is null.\n *\n * This function tests whether the provided value is strictly equal to `null`.\n * It returns `true` if the value is `null`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null`.\n *\n * @param {unknown} x - The value to test if it is null.\n * @returns {x is null} True if the value is null, false otherwise.\n *\n * @example\n * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n *\n * console.log(isNull(value1)); // true\n * console.log(isNull(value2)); // false\n * console.log(isNull(value3)); // false\n */\nexport function isNull(x: unknown): x is null {\n return x === null;\n}\n","/**\n * Checks if the given value is undefined.\n *\n * This function tests whether the provided value is strictly equal to `undefined`.\n * It returns `true` if the value is `undefined`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `undefined`.\n *\n * @param {unknown} x - The value to test if it is undefined.\n * @returns {x is undefined} true if the value is undefined, false otherwise.\n *\n * @example\n * const value1 = undefined;\n * const value2 = null;\n * const value3 = 42;\n *\n * console.log(isUndefined(value1)); // true\n * console.log(isUndefined(value2)); // false\n * console.log(isUndefined(value3)); // false\n */\nexport function isUndefined(x: unknown): x is undefined {\n return x === undefined;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACmBO,SAAS,MAAM,GAAmC;AACvD,SAAO,MAAM,QAAQ,MAAM;AAC7B;;;ACNO,SAAS,SAAY,GAAiC;AAC3D,SAAO,MAAM,QAAQ,MAAM;AAC7B;;;ACGO,SAAS,OAAO,GAAuB;AAC5C,SAAO,MAAM;AACf;;;ACFO,SAAS,YAAY,GAA4B;AACtD,SAAO,MAAM;AACf;","names":[]}
@@ -4,13 +4,13 @@ import {
4
4
  } from "../chunk-ZQNAZPSK.mjs";
5
5
  import {
6
6
  isNull
7
- } from "../chunk-Y6ZRNII6.mjs";
7
+ } from "../chunk-AIRSKN47.mjs";
8
8
  import {
9
9
  isUndefined
10
- } from "../chunk-HOQRMBSB.mjs";
10
+ } from "../chunk-VH2PV426.mjs";
11
11
  import {
12
12
  isNil
13
- } from "../chunk-KBJTBR5T.mjs";
13
+ } from "../chunk-OHQAR5AU.mjs";
14
14
  import "../chunk-2MM5EJJX.mjs";
15
15
  export {
16
16
  isNil,
@@ -10,7 +10,7 @@
10
10
  * @returns {boolean} `true` if the value is null or undefined, `false` otherwise.
11
11
  *
12
12
  * @example
13
- * * const value1 = null;
13
+ * const value1 = null;
14
14
  * const value2 = undefined;
15
15
  * const value3 = 42;
16
16
  * const result1 = isNil(value1); // true
@@ -10,7 +10,7 @@
10
10
  * @returns {boolean} `true` if the value is null or undefined, `false` otherwise.
11
11
  *
12
12
  * @example
13
- * * const value1 = null;
13
+ * const value1 = null;
14
14
  * const value2 = undefined;
15
15
  * const value3 = 42;
16
16
  * const result1 = isNil(value1); // true
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/predicate/isNil.ts"],"sourcesContent":["/**\n * Checks if a given value is null or undefined.\n *\n * This function tests whether the provided value is either `null` or `undefined`.\n * It returns `true` if the value is `null` or `undefined`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null` or `undefined`.\n *\n * @param {unknown} x - The value to test for null or undefined.\n * @returns {boolean} `true` if the value is null or undefined, `false` otherwise.\n *\n * @example\n * * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n * const result1 = isNil(value1); // true\n * const result2 = isNil(value2); // true\n * const result3 = isNil(value3); // false\n */\nexport function isNil(x: unknown): x is null | undefined {\n return x === null || x === undefined;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAmBO,SAAS,MAAM,GAAmC;AACvD,SAAO,MAAM,QAAQ,MAAM;AAC7B;","names":[]}
1
+ {"version":3,"sources":["../../src/predicate/isNil.ts"],"sourcesContent":["/**\n * Checks if a given value is null or undefined.\n *\n * This function tests whether the provided value is either `null` or `undefined`.\n * It returns `true` if the value is `null` or `undefined`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null` or `undefined`.\n *\n * @param {unknown} x - The value to test for null or undefined.\n * @returns {boolean} `true` if the value is null or undefined, `false` otherwise.\n *\n * @example\n * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n * const result1 = isNil(value1); // true\n * const result2 = isNil(value2); // true\n * const result3 = isNil(value3); // false\n */\nexport function isNil(x: unknown): x is null | undefined {\n return x === null || x === undefined;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAmBO,SAAS,MAAM,GAAmC;AACvD,SAAO,MAAM,QAAQ,MAAM;AAC7B;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isNil
3
- } from "../chunk-KBJTBR5T.mjs";
3
+ } from "../chunk-OHQAR5AU.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  isNil
@@ -10,7 +10,7 @@
10
10
  * @returns {x is null} True if the value is null, false otherwise.
11
11
  *
12
12
  * @example
13
- * * const value1 = null;
13
+ * const value1 = null;
14
14
  * const value2 = undefined;
15
15
  * const value3 = 42;
16
16
  *
@@ -10,7 +10,7 @@
10
10
  * @returns {x is null} True if the value is null, false otherwise.
11
11
  *
12
12
  * @example
13
- * * const value1 = null;
13
+ * const value1 = null;
14
14
  * const value2 = undefined;
15
15
  * const value3 = 42;
16
16
  *
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/predicate/isNull.ts"],"sourcesContent":["/**\n * Checks if the given value is null.\n *\n * This function tests whether the provided value is strictly equal to `null`.\n * It returns `true` if the value is `null`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null`.\n *\n * @param {unknown} x - The value to test if it is null.\n * @returns {x is null} True if the value is null, false otherwise.\n *\n * @example\n * * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n *\n * console.log(isNull(value1)); // true\n * console.log(isNull(value2)); // false\n * console.log(isNull(value3)); // false\n */\nexport function isNull(x: unknown): x is null {\n return x === null;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAoBO,SAAS,OAAO,GAAuB;AAC5C,SAAO,MAAM;AACf;","names":[]}
1
+ {"version":3,"sources":["../../src/predicate/isNull.ts"],"sourcesContent":["/**\n * Checks if the given value is null.\n *\n * This function tests whether the provided value is strictly equal to `null`.\n * It returns `true` if the value is `null`, and `false` otherwise.\n *\n * This function can also serve as a type predicate in TypeScript, narrowing the type of the argument to `null`.\n *\n * @param {unknown} x - The value to test if it is null.\n * @returns {x is null} True if the value is null, false otherwise.\n *\n * @example\n * const value1 = null;\n * const value2 = undefined;\n * const value3 = 42;\n *\n * console.log(isNull(value1)); // true\n * console.log(isNull(value2)); // false\n * console.log(isNull(value3)); // false\n */\nexport function isNull(x: unknown): x is null {\n return x === null;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAoBO,SAAS,OAAO,GAAuB;AAC5C,SAAO,MAAM;AACf;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isNull
3
- } from "../chunk-Y6ZRNII6.mjs";
3
+ } from "../chunk-AIRSKN47.mjs";
4
4
  import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  isNull
@@ -10,7 +10,7 @@
10
10
  * @returns {x is undefined} true if the value is undefined, false otherwise.
11
11
  *
12
12
  * @example
13
- * * const value1 = undefined;
13
+ * const value1 = undefined;
14
14
  * const value2 = null;
15
15
  * const value3 = 42;
16
16
  *
@@ -10,7 +10,7 @@
10
10
  * @returns {x is undefined} true if the value is undefined, false otherwise.
11
11
  *
12
12
  * @example
13
- * * const value1 = undefined;
13
+ * const value1 = undefined;
14
14
  * const value2 = null;
15
15
  * const value3 = 42;
16
16
  *