es-toolkit 1.25.2-dev.799 → 1.25.2-dev.802

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.
@@ -62,7 +62,7 @@ declare function find<T>(arr: ArrayLike<T> | null | undefined, propertyToCheck:
62
62
  * Finds the first item in an object that matches the given predicate function.
63
63
  *
64
64
  * @template T
65
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
65
+ * @param {T | null | undefined} object - The object to search through.
66
66
  * @param {(item: T[keyof T], index: number, arr: T) => unknown} doesMatch - A function that takes an item, its key, and the object, and returns a truthy value if the item matches the criteria.
67
67
  * @returns {T | undefined} - The first property value that matches the predicate, or `undefined` if no match is found.
68
68
  *
@@ -77,7 +77,7 @@ declare function find<T extends Record<string, unknown>>(object: T | null | unde
77
77
  * Finds the first item in an object that matches the given partial value.
78
78
  *
79
79
  * @template T
80
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
80
+ * @param {T | null | undefined} object - The object to search through.
81
81
  * @param {Partial<T[keyof T]>} doesMatch - A partial value to match against the values of the object.
82
82
  * @returns {T | undefined} - The first property value that matches the partial value, or `undefined` if no match is found.
83
83
  *
@@ -92,7 +92,7 @@ declare function find<T extends Record<string, unknown>>(object: T | null | unde
92
92
  * Finds the first item in an object that matches a property with a specific value.
93
93
  *
94
94
  * @template T
95
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
95
+ * @param {T | null | undefined} object - The object to search through.
96
96
  * @param {[keyof T, unknown]} doesMatchProperty - An array where the first element is the property key and the second element is the value to match.
97
97
  * @returns {T | undefined} - The first item that has the specified property value, or `undefined` if no match is found.
98
98
  *
@@ -107,7 +107,7 @@ declare function find<T extends Record<string, unknown>>(object: T | null | unde
107
107
  * Finds the first item in an object that has a specific property, where the property name is provided as a string.
108
108
  *
109
109
  * @template T
110
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
110
+ * @param {T | null | undefined} object - The object to search through.
111
111
  * @param {string} propertyToCheck - The property name to check.
112
112
  * @returns {T | undefined} - The first property value that has the specified property, or `undefined` if no match is found.
113
113
  *
@@ -62,7 +62,7 @@ declare function find<T>(arr: ArrayLike<T> | null | undefined, propertyToCheck:
62
62
  * Finds the first item in an object that matches the given predicate function.
63
63
  *
64
64
  * @template T
65
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
65
+ * @param {T | null | undefined} object - The object to search through.
66
66
  * @param {(item: T[keyof T], index: number, arr: T) => unknown} doesMatch - A function that takes an item, its key, and the object, and returns a truthy value if the item matches the criteria.
67
67
  * @returns {T | undefined} - The first property value that matches the predicate, or `undefined` if no match is found.
68
68
  *
@@ -77,7 +77,7 @@ declare function find<T extends Record<string, unknown>>(object: T | null | unde
77
77
  * Finds the first item in an object that matches the given partial value.
78
78
  *
79
79
  * @template T
80
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
80
+ * @param {T | null | undefined} object - The object to search through.
81
81
  * @param {Partial<T[keyof T]>} doesMatch - A partial value to match against the values of the object.
82
82
  * @returns {T | undefined} - The first property value that matches the partial value, or `undefined` if no match is found.
83
83
  *
@@ -92,7 +92,7 @@ declare function find<T extends Record<string, unknown>>(object: T | null | unde
92
92
  * Finds the first item in an object that matches a property with a specific value.
93
93
  *
94
94
  * @template T
95
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
95
+ * @param {T | null | undefined} object - The object to search through.
96
96
  * @param {[keyof T, unknown]} doesMatchProperty - An array where the first element is the property key and the second element is the value to match.
97
97
  * @returns {T | undefined} - The first item that has the specified property value, or `undefined` if no match is found.
98
98
  *
@@ -107,7 +107,7 @@ declare function find<T extends Record<string, unknown>>(object: T | null | unde
107
107
  * Finds the first item in an object that has a specific property, where the property name is provided as a string.
108
108
  *
109
109
  * @template T
110
- * @param {T extends Record<string, unknown> ? T | null | undefined: never} object - The object to search through.
110
+ * @param {T | null | undefined} object - The object to search through.
111
111
  * @param {string} propertyToCheck - The property name to check.
112
112
  * @returns {T | undefined} - The first property value that has the specified property, or `undefined` if no match is found.
113
113
  *
@@ -8,7 +8,7 @@ const unary = require('../_chunk/unary-CMvKXy.js');
8
8
  const noop = require('../_chunk/noop-2IwLUk.js');
9
9
  const sumBy = require('../_chunk/sumBy-BkErWJ.js');
10
10
  const randomInt = require('../_chunk/randomInt-CF7bZK.js');
11
- const toMerged = require('../_chunk/toMerged-BLnW4M.js');
11
+ const toMerged = require('../_chunk/toMerged-wNz52b.js');
12
12
  const isPlainObject$1 = require('../_chunk/isPlainObject-octpoD.js');
13
13
  const isWeakSet$1 = require('../_chunk/isWeakSet-D8h8bS.js');
14
14
  const upperFirst = require('../_chunk/upperFirst-BUECmK.js');
package/dist/index.js CHANGED
@@ -11,7 +11,7 @@ const noop = require('./_chunk/noop-2IwLUk.js');
11
11
  const sumBy = require('./_chunk/sumBy-BkErWJ.js');
12
12
  const randomInt = require('./_chunk/randomInt-CF7bZK.js');
13
13
  const math_index = require('./math/index.js');
14
- const toMerged = require('./_chunk/toMerged-BLnW4M.js');
14
+ const toMerged = require('./_chunk/toMerged-wNz52b.js');
15
15
  const object_index = require('./object/index.js');
16
16
  const isWeakSet = require('./_chunk/isWeakSet-D8h8bS.js');
17
17
  const predicate_index = require('./predicate/index.js');
@@ -37,7 +37,7 @@ function cloneDeepImpl(obj, stack = new Map()) {
37
37
  if (obj instanceof Map) {
38
38
  const result = new Map();
39
39
  stack.set(obj, result);
40
- for (const [key, value] of obj.entries()) {
40
+ for (const [key, value] of obj) {
41
41
  result.set(key, cloneDeepImpl(value, stack));
42
42
  }
43
43
  return result;
@@ -45,7 +45,7 @@ function cloneDeepImpl(obj, stack = new Map()) {
45
45
  if (obj instanceof Set) {
46
46
  const result = new Set();
47
47
  stack.set(obj, result);
48
- for (const value of obj.values()) {
48
+ for (const value of obj) {
49
49
  result.add(cloneDeepImpl(value, stack));
50
50
  }
51
51
  return result;
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const toMerged = require('../_chunk/toMerged-BLnW4M.js');
5
+ const toMerged = require('../_chunk/toMerged-wNz52b.js');
6
6
 
7
7
  function mergeWith(target, source, merge) {
8
8
  const sourceKeys = Object.keys(source);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "es-toolkit",
3
3
  "description": "A state-of-the-art, high-performance JavaScript utility library with a small bundle size and strong type annotations.",
4
- "version": "1.25.2-dev.799+4b2de1f6",
4
+ "version": "1.25.2-dev.802+9c7b850e",
5
5
  "homepage": "https://es-toolkit.slash.page",
6
6
  "bugs": "https://github.com/toss/es-toolkit/issues",
7
7
  "repository": {