es-toolkit 1.10.0-dev.207 → 1.10.0-dev.210

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 (111) hide show
  1. package/dist/array/chunk.mjs +1 -1
  2. package/dist/array/compact.mjs +1 -1
  3. package/dist/array/countBy.mjs +1 -1
  4. package/dist/array/difference.mjs +1 -1
  5. package/dist/array/differenceBy.mjs +1 -1
  6. package/dist/array/differenceWith.mjs +1 -1
  7. package/dist/array/drop.mjs +1 -1
  8. package/dist/array/dropRight.mjs +1 -1
  9. package/dist/array/dropRightWhile.mjs +1 -1
  10. package/dist/array/dropWhile.mjs +1 -1
  11. package/dist/array/fill.mjs +1 -1
  12. package/dist/array/flatten.mjs +1 -1
  13. package/dist/array/flattenDeep.mjs +1 -1
  14. package/dist/array/forEachRight.mjs +1 -1
  15. package/dist/array/groupBy.mjs +1 -1
  16. package/dist/array/head.mjs +1 -1
  17. package/dist/array/index.mjs +51 -51
  18. package/dist/array/initial.mjs +1 -1
  19. package/dist/array/intersection.mjs +1 -1
  20. package/dist/array/intersectionBy.mjs +1 -1
  21. package/dist/array/intersectionWith.mjs +1 -1
  22. package/dist/array/keyBy.mjs +1 -1
  23. package/dist/array/last.mjs +1 -1
  24. package/dist/array/maxBy.mjs +1 -1
  25. package/dist/array/minBy.mjs +1 -1
  26. package/dist/array/orderBy.mjs +1 -1
  27. package/dist/array/partition.mjs +1 -1
  28. package/dist/array/sample.mjs +1 -1
  29. package/dist/array/sampleSize.mjs +1 -1
  30. package/dist/array/shuffle.mjs +1 -1
  31. package/dist/array/tail.mjs +1 -1
  32. package/dist/array/take.mjs +1 -1
  33. package/dist/array/takeRight.mjs +1 -1
  34. package/dist/array/takeRightWhile.mjs +1 -1
  35. package/dist/array/takeWhile.mjs +1 -1
  36. package/dist/array/toFilled.mjs +1 -1
  37. package/dist/array/union.mjs +1 -1
  38. package/dist/array/unionBy.mjs +1 -1
  39. package/dist/array/unionWith.mjs +1 -1
  40. package/dist/array/uniq.mjs +1 -1
  41. package/dist/array/uniqBy.mjs +1 -1
  42. package/dist/array/uniqWith.mjs +1 -1
  43. package/dist/array/unzip.mjs +1 -1
  44. package/dist/array/unzipWith.mjs +1 -1
  45. package/dist/array/without.mjs +1 -1
  46. package/dist/array/xor.mjs +1 -1
  47. package/dist/array/xorBy.mjs +1 -1
  48. package/dist/array/xorWith.mjs +1 -1
  49. package/dist/array/zip.mjs +1 -1
  50. package/dist/array/zipObject.mjs +1 -1
  51. package/dist/array/zipWith.mjs +1 -1
  52. package/dist/chunk-2MM5EJJX.mjs +21 -0
  53. package/dist/{chunk-4E4D3BMI.mjs → chunk-QZITBKWX.mjs} +2 -2
  54. package/dist/chunk-Y5V7UAZZ.mjs +21 -0
  55. package/dist/chunk-Y5V7UAZZ.mjs.map +1 -0
  56. package/dist/compat/index.js +6 -5515
  57. package/dist/compat/index.js.map +1 -1
  58. package/dist/compat/index.mjs +74 -74
  59. package/dist/error/AbortError.mjs +1 -1
  60. package/dist/error/index.mjs +1 -1
  61. package/dist/function/debounce.mjs +1 -1
  62. package/dist/function/index.mjs +7 -7
  63. package/dist/function/negate.mjs +1 -1
  64. package/dist/function/noop.mjs +1 -1
  65. package/dist/function/once.mjs +1 -1
  66. package/dist/function/throttle.mjs +1 -1
  67. package/dist/index.js +6 -5515
  68. package/dist/index.js.map +1 -1
  69. package/dist/index.mjs +74 -74
  70. package/dist/math/clamp.mjs +1 -1
  71. package/dist/math/inRange.mjs +1 -1
  72. package/dist/math/index.mjs +1 -1
  73. package/dist/math/mean.mjs +1 -1
  74. package/dist/math/meanBy.mjs +1 -1
  75. package/dist/math/random.mjs +1 -1
  76. package/dist/math/randomInt.mjs +1 -1
  77. package/dist/math/range.mjs +1 -1
  78. package/dist/math/round.mjs +1 -1
  79. package/dist/math/sum.mjs +1 -1
  80. package/dist/math/sumBy.mjs +1 -1
  81. package/dist/object/clone.mjs +1 -1
  82. package/dist/object/index.mjs +2 -2
  83. package/dist/object/invert.mjs +1 -1
  84. package/dist/object/omit.mjs +2 -2
  85. package/dist/object/omitBy.mjs +1 -1
  86. package/dist/object/pick.mjs +1 -1
  87. package/dist/object/pickBy.mjs +1 -1
  88. package/dist/predicate/index.mjs +1 -1
  89. package/dist/predicate/isEqual.mjs +1 -1
  90. package/dist/predicate/isNil.mjs +1 -1
  91. package/dist/predicate/isNotNil.mjs +1 -1
  92. package/dist/predicate/isNull.mjs +1 -1
  93. package/dist/predicate/isUndefined.mjs +1 -1
  94. package/dist/promise/delay.mjs +1 -1
  95. package/dist/promise/index.mjs +1 -1
  96. package/dist/string/camelCase.js +6 -5508
  97. package/dist/string/camelCase.js.map +1 -1
  98. package/dist/string/camelCase.mjs +3 -2
  99. package/dist/string/capitalize.mjs +1 -1
  100. package/dist/string/index.js +6 -5515
  101. package/dist/string/index.js.map +1 -1
  102. package/dist/string/index.mjs +5 -5
  103. package/dist/string/kebabCase.mjs +1 -1
  104. package/dist/string/lowerCase.mjs +1 -1
  105. package/dist/string/snakeCase.mjs +1 -1
  106. package/package.json +1 -1
  107. package/dist/chunk-2HIMLZE3.mjs +0 -46
  108. package/dist/chunk-XGCYC4YA.mjs +0 -5516
  109. package/dist/chunk-XGCYC4YA.mjs.map +0 -1
  110. /package/dist/{chunk-2HIMLZE3.mjs.map → chunk-2MM5EJJX.mjs.map} +0 -0
  111. /package/dist/{chunk-4E4D3BMI.mjs.map → chunk-QZITBKWX.mjs.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  zipWith
3
3
  } from "../chunk-4KYXHZ4R.mjs";
4
- import "../chunk-2HIMLZE3.mjs";
4
+ import "../chunk-2MM5EJJX.mjs";
5
5
  export {
6
6
  zipWith
7
7
  };
@@ -0,0 +1,21 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
4
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
5
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6
+ var __spreadValues = (a, b) => {
7
+ for (var prop in b || (b = {}))
8
+ if (__hasOwnProp.call(b, prop))
9
+ __defNormalProp(a, prop, b[prop]);
10
+ if (__getOwnPropSymbols)
11
+ for (var prop of __getOwnPropSymbols(b)) {
12
+ if (__propIsEnum.call(b, prop))
13
+ __defNormalProp(a, prop, b[prop]);
14
+ }
15
+ return a;
16
+ };
17
+
18
+ export {
19
+ __spreadValues
20
+ };
21
+ //# sourceMappingURL=chunk-2MM5EJJX.mjs.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  __spreadValues
3
- } from "./chunk-2HIMLZE3.mjs";
3
+ } from "./chunk-2MM5EJJX.mjs";
4
4
 
5
5
  // src/object/omit.ts
6
6
  function omit(obj, keys) {
@@ -14,4 +14,4 @@ function omit(obj, keys) {
14
14
  export {
15
15
  omit
16
16
  };
17
- //# sourceMappingURL=chunk-4E4D3BMI.mjs.map
17
+ //# sourceMappingURL=chunk-QZITBKWX.mjs.map
@@ -0,0 +1,21 @@
1
+ import {
2
+ capitalize
3
+ } from "./chunk-U56ZOM7L.mjs";
4
+ import {
5
+ getWords
6
+ } from "./chunk-WVQ7YVRK.mjs";
7
+
8
+ // src/string/camelCase.ts
9
+ function camelCase(str) {
10
+ const words = getWords(str);
11
+ if (words.length === 0) {
12
+ return "";
13
+ }
14
+ const [first, ...rest] = words;
15
+ return `${first.toLowerCase()}${rest.map((word) => capitalize(word)).join("")}`;
16
+ }
17
+
18
+ export {
19
+ camelCase
20
+ };
21
+ //# sourceMappingURL=chunk-Y5V7UAZZ.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/string/camelCase.ts"],"sourcesContent":["import { capitalize } from \"./capitalize.ts\";\nimport { getWords } from \"./_internal/getWords.ts\";\n\n/**\n * Converts a string to camel case.\n *\n * camel case is the naming convention in which each word is written in lowercase and separated by an underscore (_) character.\n *\n * @param {string} str - The string that is to be changed to camel case.\n * @returns {string} - The converted string to camel case.\n *\n * @example\n * const convertedStr1 = camelCase('camelCase') // returns 'camelCase'\n * const convertedStr2 = camelCase('some whitespace') // returns 'someWhitespace'\n * const convertedStr3 = camelCase('hyphen-text') // returns 'hyphenText'\n * const convertedStr4 = camelCase('HTTPRequest') // returns 'httpRequest'\n */\n\nexport function camelCase(str: string): string {\n const words = getWords(str);\n\n if (words.length === 0) {\n return \"\";\n }\n\n const [first, ...rest] = words;\n\n return `${first.toLowerCase()}${rest.map((word) => capitalize(word)).join(\"\")\n }`;\n}\n"],"mappings":";;;;;;;;AAkBO,SAAS,UAAU,KAAqB;AAC7C,QAAM,QAAQ,SAAS,GAAG;AAE1B,MAAI,MAAM,WAAW,GAAG;AACtB,WAAO;AAAA,EACT;AAEA,QAAM,CAAC,OAAO,GAAG,IAAI,IAAI;AAEzB,SAAO,GAAG,MAAM,YAAY,CAAC,GAAG,KAAK,IAAI,CAAC,SAAS,WAAW,IAAI,CAAC,EAAE,KAAK,EAAE,CAC1E;AACJ;","names":[]}