es-toolkit 1.13.1-dev.320 → 1.13.1-dev.322

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 (251) hide show
  1. package/dist/array/chunk.mjs +1 -1
  2. package/dist/array/compact.d.mts +1 -1
  3. package/dist/array/compact.d.ts +1 -1
  4. package/dist/array/compact.js.map +1 -1
  5. package/dist/array/compact.mjs +2 -2
  6. package/dist/array/countBy.js +1 -2
  7. package/dist/array/countBy.js.map +1 -1
  8. package/dist/array/countBy.mjs +2 -2
  9. package/dist/array/difference.mjs +1 -1
  10. package/dist/array/differenceBy.mjs +1 -1
  11. package/dist/array/differenceWith.mjs +1 -1
  12. package/dist/array/drop.mjs +1 -1
  13. package/dist/array/dropRight.mjs +1 -1
  14. package/dist/array/dropRightWhile.mjs +1 -1
  15. package/dist/array/dropWhile.mjs +1 -1
  16. package/dist/array/fill.d.mts +1 -0
  17. package/dist/array/fill.d.ts +1 -0
  18. package/dist/array/fill.js.map +1 -1
  19. package/dist/array/fill.mjs +2 -2
  20. package/dist/array/flatMap.mjs +1 -1
  21. package/dist/array/flatten.mjs +1 -1
  22. package/dist/array/flattenDeep.mjs +1 -1
  23. package/dist/array/forEachRight.mjs +1 -1
  24. package/dist/array/groupBy.mjs +1 -1
  25. package/dist/array/head.d.mts +1 -0
  26. package/dist/array/head.d.ts +1 -0
  27. package/dist/array/head.js.map +1 -1
  28. package/dist/array/head.mjs +2 -2
  29. package/dist/array/index.js +1 -2
  30. package/dist/array/index.js.map +1 -1
  31. package/dist/array/index.mjs +56 -56
  32. package/dist/array/initial.mjs +1 -1
  33. package/dist/array/intersection.mjs +1 -1
  34. package/dist/array/intersectionBy.mjs +1 -1
  35. package/dist/array/intersectionWith.mjs +1 -1
  36. package/dist/array/keyBy.mjs +1 -1
  37. package/dist/array/last.d.mts +1 -0
  38. package/dist/array/last.d.ts +1 -0
  39. package/dist/array/last.js.map +1 -1
  40. package/dist/array/last.mjs +2 -2
  41. package/dist/array/maxBy.mjs +1 -1
  42. package/dist/array/minBy.mjs +1 -1
  43. package/dist/array/orderBy.mjs +1 -1
  44. package/dist/array/partition.mjs +1 -1
  45. package/dist/array/sample.mjs +1 -1
  46. package/dist/array/sampleSize.mjs +1 -1
  47. package/dist/array/shuffle.mjs +1 -1
  48. package/dist/array/tail.d.mts +9 -4
  49. package/dist/array/tail.d.ts +9 -4
  50. package/dist/array/tail.js.map +1 -1
  51. package/dist/array/tail.mjs +2 -2
  52. package/dist/array/take.mjs +1 -1
  53. package/dist/array/takeRight.mjs +1 -1
  54. package/dist/array/takeRightWhile.mjs +1 -1
  55. package/dist/array/takeWhile.mjs +1 -1
  56. package/dist/array/toFilled.d.mts +2 -0
  57. package/dist/array/toFilled.d.ts +2 -0
  58. package/dist/array/toFilled.js.map +1 -1
  59. package/dist/array/toFilled.mjs +2 -2
  60. package/dist/array/union.mjs +1 -1
  61. package/dist/array/unionBy.mjs +1 -1
  62. package/dist/array/unionWith.mjs +1 -1
  63. package/dist/array/uniq.mjs +1 -1
  64. package/dist/array/uniqBy.mjs +1 -1
  65. package/dist/array/uniqWith.mjs +1 -1
  66. package/dist/array/unzip.d.mts +3 -2
  67. package/dist/array/unzip.d.ts +3 -2
  68. package/dist/array/unzip.js.map +1 -1
  69. package/dist/array/unzip.mjs +2 -2
  70. package/dist/array/unzipWith.mjs +1 -1
  71. package/dist/array/without.mjs +1 -1
  72. package/dist/array/xor.mjs +1 -1
  73. package/dist/array/xorBy.mjs +1 -1
  74. package/dist/array/xorWith.mjs +1 -1
  75. package/dist/array/zip.mjs +1 -1
  76. package/dist/array/zipObject.mjs +1 -1
  77. package/dist/array/zipWith.d.mts +5 -0
  78. package/dist/array/zipWith.d.ts +5 -0
  79. package/dist/array/zipWith.js.map +1 -1
  80. package/dist/array/zipWith.mjs +2 -2
  81. package/dist/browser.js +22 -58
  82. package/dist/browser.js.map +1 -1
  83. package/dist/browser.mjs +54 -53
  84. package/dist/browser.mjs.map +1 -1
  85. package/dist/{chunk-QXTNZR7B.mjs → chunk-3SBT6WDU.mjs} +2 -2
  86. package/dist/{chunk-O64NE2P4.mjs → chunk-4DFAGGIM.mjs} +3 -3
  87. package/dist/{chunk-O64NE2P4.mjs.map → chunk-4DFAGGIM.mjs.map} +1 -1
  88. package/dist/{chunk-Y5V7UAZZ.mjs → chunk-4ZES5T6V.mjs} +4 -4
  89. package/dist/{chunk-TJ4Z5I7M.mjs → chunk-DLS7UJKJ.mjs} +1 -1
  90. package/dist/chunk-DLS7UJKJ.mjs.map +1 -0
  91. package/dist/{chunk-KPBQ7OUY.mjs → chunk-DTTKJ3VC.mjs} +1 -1
  92. package/dist/chunk-DTTKJ3VC.mjs.map +1 -0
  93. package/dist/{chunk-YNJH6GEG.mjs → chunk-EEHJ656S.mjs} +95 -92
  94. package/dist/chunk-EEHJ656S.mjs.map +1 -0
  95. package/dist/{chunk-EYYZQFOP.mjs → chunk-ET33L3MQ.mjs} +2 -2
  96. package/dist/chunk-EZYYB34V.mjs +17 -0
  97. package/dist/{chunk-CVVZHOJX.mjs.map → chunk-EZYYB34V.mjs.map} +1 -1
  98. package/dist/{chunk-HM2JT2RX.mjs → chunk-FZZNWXDM.mjs} +1 -1
  99. package/dist/chunk-FZZNWXDM.mjs.map +1 -0
  100. package/dist/{chunk-YFN6KOC4.mjs → chunk-GTFDDKZ2.mjs} +1 -1
  101. package/dist/chunk-GTFDDKZ2.mjs.map +1 -0
  102. package/dist/{chunk-F3WCQQET.mjs → chunk-IWXZI3QT.mjs} +2 -2
  103. package/dist/chunk-J5LGTIGS.mjs +10 -0
  104. package/dist/{chunk-UYZKMBDO.mjs → chunk-JCRY7ZYS.mjs} +1 -1
  105. package/dist/chunk-JCRY7ZYS.mjs.map +1 -0
  106. package/dist/{chunk-5CPXZFCB.mjs → chunk-K5WL54BY.mjs} +2 -2
  107. package/dist/{chunk-5CPXZFCB.mjs.map → chunk-K5WL54BY.mjs.map} +1 -1
  108. package/dist/{chunk-4KYXHZ4R.mjs → chunk-MJ7LNBI6.mjs} +1 -1
  109. package/dist/chunk-MJ7LNBI6.mjs.map +1 -0
  110. package/dist/{chunk-3IP4JVLL.mjs → chunk-MSHSKENG.mjs} +3 -3
  111. package/dist/{chunk-3IP4JVLL.mjs.map → chunk-MSHSKENG.mjs.map} +1 -1
  112. package/dist/{chunk-WVQ7YVRK.mjs → chunk-OG2RLT5U.mjs} +2 -3
  113. package/dist/{chunk-WVQ7YVRK.mjs.map → chunk-OG2RLT5U.mjs.map} +1 -1
  114. package/dist/{chunk-DTJJIMKJ.mjs → chunk-PJPGJ2O6.mjs} +1 -1
  115. package/dist/chunk-PJPGJ2O6.mjs.map +1 -0
  116. package/dist/chunk-R6GLTTAB.mjs +9 -0
  117. package/dist/chunk-R6GLTTAB.mjs.map +1 -0
  118. package/dist/{chunk-5IKVJGHO.mjs → chunk-RTFTLCF3.mjs} +2 -2
  119. package/dist/{chunk-OP4OAKQJ.mjs → chunk-XHSIT5DL.mjs} +1 -1
  120. package/dist/chunk-XHSIT5DL.mjs.map +1 -0
  121. package/dist/{chunk-WFZXCGEG.mjs → chunk-YOPFSFTD.mjs} +2 -6
  122. package/dist/{chunk-WFZXCGEG.mjs.map → chunk-YOPFSFTD.mjs.map} +1 -1
  123. package/dist/chunk-YXD3AQAK.mjs +1 -0
  124. package/dist/{chunk-CRSKT4WW.mjs → chunk-Z7HWEOQX.mjs} +2 -3
  125. package/dist/{chunk-CRSKT4WW.mjs.map → chunk-Z7HWEOQX.mjs.map} +1 -1
  126. package/dist/chunk-ZPNX2QDE.mjs +13 -0
  127. package/dist/{chunk-IIDZ3KAJ.mjs.map → chunk-ZPNX2QDE.mjs.map} +1 -1
  128. package/dist/compat/index.d.mts +3 -1
  129. package/dist/compat/index.d.ts +3 -1
  130. package/dist/compat/index.js +23 -57
  131. package/dist/compat/index.js.map +1 -1
  132. package/dist/compat/index.mjs +98 -94
  133. package/dist/error/AbortError.mjs +1 -1
  134. package/dist/error/TimeoutError.mjs +1 -1
  135. package/dist/error/index.mjs +4 -4
  136. package/dist/function/after.mjs +1 -1
  137. package/dist/function/debounce.js +2 -2
  138. package/dist/function/debounce.js.map +1 -1
  139. package/dist/function/debounce.mjs +2 -2
  140. package/dist/function/index.js +2 -2
  141. package/dist/function/index.js.map +1 -1
  142. package/dist/function/index.mjs +10 -10
  143. package/dist/function/negate.mjs +1 -1
  144. package/dist/function/noop.mjs +1 -1
  145. package/dist/function/once.mjs +1 -1
  146. package/dist/function/throttle.mjs +1 -1
  147. package/dist/index.d.mts +1 -0
  148. package/dist/index.d.ts +1 -0
  149. package/dist/index.js +20 -53
  150. package/dist/index.js.map +1 -1
  151. package/dist/index.mjs +97 -93
  152. package/dist/math/clamp.mjs +1 -1
  153. package/dist/math/inRange.mjs +1 -1
  154. package/dist/math/index.mjs +1 -1
  155. package/dist/math/mean.mjs +1 -1
  156. package/dist/math/meanBy.mjs +1 -1
  157. package/dist/math/random.mjs +1 -1
  158. package/dist/math/randomInt.mjs +1 -1
  159. package/dist/math/range.mjs +1 -1
  160. package/dist/math/round.mjs +1 -1
  161. package/dist/math/sum.mjs +1 -1
  162. package/dist/math/sumBy.mjs +1 -1
  163. package/dist/object/clone.mjs +1 -1
  164. package/dist/object/cloneDeep.js +1 -1
  165. package/dist/object/cloneDeep.js.map +1 -1
  166. package/dist/object/cloneDeep.mjs +2 -2
  167. package/dist/object/flattenObject.mjs +1 -1
  168. package/dist/object/index.js +2 -16
  169. package/dist/object/index.js.map +1 -1
  170. package/dist/object/index.mjs +3 -3
  171. package/dist/object/invert.mjs +1 -1
  172. package/dist/object/omit.js +1 -15
  173. package/dist/object/omit.js.map +1 -1
  174. package/dist/object/omit.mjs +2 -2
  175. package/dist/object/omitBy.mjs +1 -1
  176. package/dist/object/pick.mjs +1 -1
  177. package/dist/object/pickBy.mjs +1 -1
  178. package/dist/predicate/index.d.mts +1 -0
  179. package/dist/predicate/index.d.ts +1 -0
  180. package/dist/predicate/index.js +7 -0
  181. package/dist/predicate/index.js.map +1 -1
  182. package/dist/predicate/index.mjs +9 -5
  183. package/dist/predicate/isArrayLike.mjs +1 -1
  184. package/dist/predicate/isEqual.mjs +1 -1
  185. package/dist/predicate/isFunction.mjs +1 -1
  186. package/dist/predicate/isLength.mjs +1 -1
  187. package/dist/predicate/isNil.mjs +1 -1
  188. package/dist/predicate/isNotNil.mjs +1 -1
  189. package/dist/predicate/isNull.mjs +1 -1
  190. package/dist/predicate/isPlainObject.mjs +1 -1
  191. package/dist/predicate/isPrimitive.d.mts +17 -0
  192. package/dist/predicate/isPrimitive.d.ts +17 -0
  193. package/dist/predicate/isPrimitive.js +33 -0
  194. package/dist/predicate/isPrimitive.js.map +1 -0
  195. package/dist/predicate/isPrimitive.mjs +8 -0
  196. package/dist/predicate/isPrimitive.mjs.map +1 -0
  197. package/dist/predicate/isTypedArray.mjs +1 -1
  198. package/dist/predicate/isUndefined.mjs +1 -1
  199. package/dist/promise/delay.js +2 -2
  200. package/dist/promise/delay.js.map +1 -1
  201. package/dist/promise/delay.mjs +2 -2
  202. package/dist/promise/index.js +7 -31
  203. package/dist/promise/index.js.map +1 -1
  204. package/dist/promise/index.mjs +5 -5
  205. package/dist/promise/timeout.js +5 -27
  206. package/dist/promise/timeout.js.map +1 -1
  207. package/dist/promise/timeout.mjs +4 -4
  208. package/dist/promise/withTimeout.js +7 -31
  209. package/dist/promise/withTimeout.js.map +1 -1
  210. package/dist/promise/withTimeout.mjs +5 -5
  211. package/dist/string/camelCase.js +1 -2
  212. package/dist/string/camelCase.js.map +1 -1
  213. package/dist/string/camelCase.mjs +3 -3
  214. package/dist/string/capitalize.mjs +1 -1
  215. package/dist/string/index.js +1 -2
  216. package/dist/string/index.js.map +1 -1
  217. package/dist/string/index.mjs +9 -9
  218. package/dist/string/kebabCase.js +1 -2
  219. package/dist/string/kebabCase.js.map +1 -1
  220. package/dist/string/kebabCase.mjs +3 -3
  221. package/dist/string/lowerCase.js +1 -2
  222. package/dist/string/lowerCase.js.map +1 -1
  223. package/dist/string/lowerCase.mjs +3 -3
  224. package/dist/string/snakeCase.js +1 -2
  225. package/dist/string/snakeCase.js.map +1 -1
  226. package/dist/string/snakeCase.mjs +3 -3
  227. package/dist/string/startCase.js +1 -2
  228. package/dist/string/startCase.js.map +1 -1
  229. package/dist/string/startCase.mjs +3 -3
  230. package/package.json +1 -1
  231. package/umd/browser.global.js +1 -1
  232. package/dist/chunk-24FKGR6U.mjs +0 -47
  233. package/dist/chunk-4KYXHZ4R.mjs.map +0 -1
  234. package/dist/chunk-CVVZHOJX.mjs +0 -22
  235. package/dist/chunk-DTJJIMKJ.mjs.map +0 -1
  236. package/dist/chunk-HM2JT2RX.mjs.map +0 -1
  237. package/dist/chunk-IIDZ3KAJ.mjs +0 -18
  238. package/dist/chunk-KPBQ7OUY.mjs.map +0 -1
  239. package/dist/chunk-OP4OAKQJ.mjs.map +0 -1
  240. package/dist/chunk-STL6TD3L.mjs +0 -1
  241. package/dist/chunk-TJ4Z5I7M.mjs.map +0 -1
  242. package/dist/chunk-UYZKMBDO.mjs.map +0 -1
  243. package/dist/chunk-YFN6KOC4.mjs.map +0 -1
  244. package/dist/chunk-YNJH6GEG.mjs.map +0 -1
  245. /package/dist/{chunk-QXTNZR7B.mjs.map → chunk-3SBT6WDU.mjs.map} +0 -0
  246. /package/dist/{chunk-Y5V7UAZZ.mjs.map → chunk-4ZES5T6V.mjs.map} +0 -0
  247. /package/dist/{chunk-EYYZQFOP.mjs.map → chunk-ET33L3MQ.mjs.map} +0 -0
  248. /package/dist/{chunk-F3WCQQET.mjs.map → chunk-IWXZI3QT.mjs.map} +0 -0
  249. /package/dist/{chunk-24FKGR6U.mjs.map → chunk-J5LGTIGS.mjs.map} +0 -0
  250. /package/dist/{chunk-5IKVJGHO.mjs.map → chunk-RTFTLCF3.mjs.map} +0 -0
  251. /package/dist/{chunk-STL6TD3L.mjs.map → chunk-YXD3AQAK.mjs.map} +0 -0
@@ -2,21 +2,7 @@
2
2
  var __defProp = Object.defineProperty;
3
3
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
4
  var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
6
5
  var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
8
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
9
- var __spreadValues = (a, b) => {
10
- for (var prop in b || (b = {}))
11
- if (__hasOwnProp.call(b, prop))
12
- __defNormalProp(a, prop, b[prop]);
13
- if (__getOwnPropSymbols)
14
- for (var prop of __getOwnPropSymbols(b)) {
15
- if (__propIsEnum.call(b, prop))
16
- __defNormalProp(a, prop, b[prop]);
17
- }
18
- return a;
19
- };
20
6
  var __export = (target, all) => {
21
7
  for (var name in all)
22
8
  __defProp(target, name, { get: all[name], enumerable: true });
@@ -30,26 +16,6 @@ var __copyProps = (to, from, except, desc) => {
30
16
  return to;
31
17
  };
32
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
33
- var __async = (__this, __arguments, generator) => {
34
- return new Promise((resolve, reject) => {
35
- var fulfilled = (value) => {
36
- try {
37
- step(generator.next(value));
38
- } catch (e) {
39
- reject(e);
40
- }
41
- };
42
- var rejected = (value) => {
43
- try {
44
- step(generator.throw(value));
45
- } catch (e) {
46
- reject(e);
47
- }
48
- };
49
- var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
50
- step((generator = generator.apply(__this, __arguments)).next());
51
- });
52
- };
53
19
 
54
20
  // src/compat/index.ts
55
21
  var compat_exports = {};
@@ -101,6 +67,7 @@ __export(compat_exports, {
101
67
  isNotNil: () => isNotNil,
102
68
  isNull: () => isNull,
103
69
  isPlainObject: () => isPlainObject2,
70
+ isPrimitive: () => isPrimitive3,
104
71
  isTypedArray: () => isTypedArray3,
105
72
  isUndefined: () => isUndefined,
106
73
  kebabCase: () => kebabCase,
@@ -190,11 +157,10 @@ function compact(arr) {
190
157
 
191
158
  // src/array/countBy.ts
192
159
  function countBy(arr, mapper) {
193
- var _a;
194
160
  const result = {};
195
161
  for (const item of arr) {
196
162
  const key = mapper(item);
197
- result[key] = ((_a = result[key]) != null ? _a : 0) + 1;
163
+ result[key] = (result[key] ?? 0) + 1;
198
164
  }
199
165
  return result;
200
166
  }
@@ -725,7 +691,7 @@ function debounce(func, debounceMs, { signal } = {}) {
725
691
  if (timeoutId !== null) {
726
692
  clearTimeout(timeoutId);
727
693
  }
728
- if (signal == null ? void 0 : signal.aborted) {
694
+ if (signal?.aborted) {
729
695
  return;
730
696
  }
731
697
  timeoutId = setTimeout(() => {
@@ -742,7 +708,7 @@ function debounce(func, debounceMs, { signal } = {}) {
742
708
  timeoutId = null;
743
709
  }
744
710
  };
745
- signal == null ? void 0 : signal.addEventListener("abort", onAbort, { once: true });
711
+ signal?.addEventListener("abort", onAbort, { once: true });
746
712
  return debounced;
747
713
  }
748
714
 
@@ -860,7 +826,7 @@ function range(start, end, step) {
860
826
 
861
827
  // src/object/omit.ts
862
828
  function omit(obj, keys) {
863
- const result = __spreadValues({}, obj);
829
+ const result = { ...obj };
864
830
  for (const key of keys) {
865
831
  delete result[key];
866
832
  }
@@ -1030,7 +996,7 @@ function cloneDeepHelper(obj, clonedObj) {
1030
996
  for (const key in obj) {
1031
997
  if (Object.prototype.hasOwnProperty.call(obj, key)) {
1032
998
  const descriptor = Object.getOwnPropertyDescriptor(obj, key);
1033
- if (((descriptor == null ? void 0 : descriptor.writable) || (descriptor == null ? void 0 : descriptor.set)) && typeof (descriptor == null ? void 0 : descriptor.value) !== "function") {
999
+ if ((descriptor?.writable || descriptor?.set) && typeof descriptor?.value !== "function") {
1034
1000
  clonedObj[key] = cloneDeep(obj[key]);
1035
1001
  }
1036
1002
  }
@@ -1160,6 +1126,11 @@ function isTypedArray2(x) {
1160
1126
  return x instanceof Uint8Array || x instanceof Uint8ClampedArray || x instanceof Uint16Array || x instanceof Uint32Array || x instanceof BigUint64Array || x instanceof Int8Array || x instanceof Int16Array || x instanceof Int32Array || x instanceof BigInt64Array || x instanceof Float32Array || x instanceof Float64Array;
1161
1127
  }
1162
1128
 
1129
+ // src/predicate/isPrimitive.ts
1130
+ function isPrimitive3(value) {
1131
+ return value == null || typeof value !== "object" && typeof value !== "function";
1132
+ }
1133
+
1163
1134
  // src/promise/delay.ts
1164
1135
  function delay(ms, { signal } = {}) {
1165
1136
  return new Promise((resolve, reject) => {
@@ -1170,27 +1141,23 @@ function delay(ms, { signal } = {}) {
1170
1141
  clearTimeout(timeoutId);
1171
1142
  abortError();
1172
1143
  };
1173
- if (signal == null ? void 0 : signal.aborted) {
1144
+ if (signal?.aborted) {
1174
1145
  return abortError();
1175
1146
  }
1176
1147
  const timeoutId = setTimeout(resolve, ms);
1177
- signal == null ? void 0 : signal.addEventListener("abort", abortHandler, { once: true });
1148
+ signal?.addEventListener("abort", abortHandler, { once: true });
1178
1149
  });
1179
1150
  }
1180
1151
 
1181
1152
  // src/promise/timeout.ts
1182
- function timeout(ms) {
1183
- return __async(this, null, function* () {
1184
- yield delay(ms);
1185
- throw new TimeoutError();
1186
- });
1153
+ async function timeout(ms) {
1154
+ await delay(ms);
1155
+ throw new TimeoutError();
1187
1156
  }
1188
1157
 
1189
1158
  // src/promise/withTimeout.ts
1190
- function withTimeout(run, ms) {
1191
- return __async(this, null, function* () {
1192
- return Promise.race([run(), timeout(ms)]);
1193
- });
1159
+ async function withTimeout(run, ms) {
1160
+ return Promise.race([run(), timeout(ms)]);
1194
1161
  }
1195
1162
 
1196
1163
  // src/string/capitalize.ts
@@ -1201,8 +1168,7 @@ var capitalize = (str) => {
1201
1168
  // src/string/_internal/getWords.ts
1202
1169
  var CASE_SPLIT_PATTERN = /[A-Z]?[a-z]+|[0-9]+|[A-Z]+(?![a-z])/g;
1203
1170
  function getWords(str) {
1204
- var _a;
1205
- return Array.from((_a = str.match(CASE_SPLIT_PATTERN)) != null ? _a : []);
1171
+ return Array.from(str.match(CASE_SPLIT_PATTERN) ?? []);
1206
1172
  }
1207
1173
 
1208
1174
  // src/string/camelCase.ts
@@ -1384,7 +1350,7 @@ function get(object, path, defaultValue) {
1384
1350
  let resolvedPath;
1385
1351
  if (Array.isArray(path)) {
1386
1352
  resolvedPath = path;
1387
- } else if (typeof path === "string" && isDeepKey(path) && (object == null ? void 0 : object[path]) == null) {
1353
+ } else if (typeof path === "string" && isDeepKey(path) && object?.[path] == null) {
1388
1354
  resolvedPath = toPath(path);
1389
1355
  } else {
1390
1356
  resolvedPath = [path];
@@ -1404,12 +1370,11 @@ function get(object, path, defaultValue) {
1404
1370
  if (current === null && index === resolvedPath.length) {
1405
1371
  return current;
1406
1372
  }
1407
- return current != null ? current : defaultValue;
1373
+ return current ?? defaultValue;
1408
1374
  }
1409
1375
 
1410
1376
  // src/compat/predicate/isPlainObject.ts
1411
1377
  function isPlainObject2(object) {
1412
- var _a;
1413
1378
  if (typeof object !== "object") {
1414
1379
  return false;
1415
1380
  }
@@ -1424,7 +1389,7 @@ function isPlainObject2(object) {
1424
1389
  if (tag == null) {
1425
1390
  return false;
1426
1391
  }
1427
- const isTagReadonly = !((_a = Object.getOwnPropertyDescriptor(object, Symbol.toStringTag)) == null ? void 0 : _a.writable);
1392
+ const isTagReadonly = !Object.getOwnPropertyDescriptor(object, Symbol.toStringTag)?.writable;
1428
1393
  if (isTagReadonly) {
1429
1394
  return false;
1430
1395
  }
@@ -1531,6 +1496,7 @@ function min(items = []) {
1531
1496
  isNotNil,
1532
1497
  isNull,
1533
1498
  isPlainObject,
1499
+ isPrimitive,
1534
1500
  isTypedArray,
1535
1501
  isUndefined,
1536
1502
  kebabCase,