es-toolkit 1.13.1 → 1.14.0-dev.399
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -1
- package/dist/_chunk/index-CwRt_M.js +46 -0
- package/dist/_chunk/initial-BTrQy1.js +514 -0
- package/dist/_chunk/isFunction-Cw_tLG.js +246 -0
- package/dist/_chunk/isTypedArray-BBEkFl.js +43 -0
- package/dist/_chunk/randomInt-CF7bZK.js +19 -0
- package/dist/array/chunk.mjs +15 -8
- package/dist/array/compact.d.mts +1 -1
- package/dist/array/compact.d.ts +1 -1
- package/dist/array/compact.mjs +11 -8
- package/dist/array/countBy.mjs +10 -8
- package/dist/array/difference.mjs +6 -8
- package/dist/array/differenceBy.mjs +8 -8
- package/dist/array/differenceWith.mjs +9 -8
- package/dist/array/drop.mjs +6 -8
- package/dist/array/dropRight.mjs +9 -8
- package/dist/array/dropRightWhile.mjs +10 -8
- package/dist/array/dropWhile.mjs +9 -8
- package/dist/array/fill.d.mts +1 -0
- package/dist/array/fill.d.ts +1 -0
- package/dist/array/fill.mjs +11 -8
- package/dist/array/flatMap.mjs +7 -9
- package/dist/array/flatten.mjs +18 -8
- package/dist/array/flattenDeep.mjs +7 -9
- package/dist/array/forEachRight.mjs +8 -8
- package/dist/array/groupBy.mjs +13 -8
- package/dist/array/head.d.mts +1 -0
- package/dist/array/head.d.ts +1 -0
- package/dist/array/head.mjs +5 -8
- package/dist/array/index.d.mts +1 -0
- package/dist/array/index.d.ts +1 -0
- package/dist/array/index.js +58 -652
- package/dist/array/index.mjs +52 -211
- package/dist/array/initial.mjs +8 -8
- package/dist/array/intersection.mjs +8 -8
- package/dist/array/intersectionBy.mjs +6 -8
- package/dist/array/intersectionWith.mjs +9 -8
- package/dist/array/isSubset.d.mts +26 -0
- package/dist/array/isSubset.d.ts +26 -0
- package/dist/array/isSubset.mjs +7 -0
- package/dist/array/keyBy.mjs +10 -8
- package/dist/array/last.d.mts +1 -0
- package/dist/array/last.d.ts +1 -0
- package/dist/array/last.mjs +5 -8
- package/dist/array/maxBy.mjs +14 -8
- package/dist/array/minBy.mjs +14 -8
- package/dist/array/orderBy.mjs +25 -8
- package/dist/array/partition.mjs +15 -8
- package/dist/array/sample.mjs +6 -8
- package/dist/array/sampleSize.mjs +20 -10
- package/dist/array/shuffle.mjs +10 -8
- package/dist/array/tail.d.mts +9 -4
- package/dist/array/tail.d.ts +9 -4
- package/dist/array/tail.mjs +13 -8
- package/dist/array/take.mjs +5 -8
- package/dist/array/takeRight.d.mts +2 -2
- package/dist/array/takeRight.d.ts +2 -2
- package/dist/array/takeRight.mjs +8 -8
- package/dist/array/takeRightWhile.mjs +10 -8
- package/dist/array/takeWhile.mjs +12 -8
- package/dist/array/toFilled.d.mts +5 -3
- package/dist/array/toFilled.d.ts +5 -3
- package/dist/array/toFilled.mjs +12 -8
- package/dist/array/union.mjs +7 -9
- package/dist/array/unionBy.mjs +12 -8
- package/dist/array/unionWith.mjs +7 -9
- package/dist/array/uniq.mjs +5 -8
- package/dist/array/uniqBy.mjs +12 -8
- package/dist/array/uniqWith.mjs +12 -8
- package/dist/array/unzip.d.mts +3 -2
- package/dist/array/unzip.d.ts +3 -2
- package/dist/array/unzip.mjs +18 -8
- package/dist/array/unzipWith.mjs +14 -8
- package/dist/array/without.mjs +6 -8
- package/dist/array/xor.mjs +9 -12
- package/dist/array/xorBy.mjs +11 -11
- package/dist/array/xorWith.mjs +11 -12
- package/dist/array/zip.d.mts +1 -0
- package/dist/array/zip.d.ts +1 -0
- package/dist/array/zip.mjs +14 -8
- package/dist/array/zipObject.d.mts +1 -1
- package/dist/array/zipObject.d.ts +1 -1
- package/dist/array/zipObject.mjs +9 -8
- package/dist/array/zipWith.d.mts +5 -0
- package/dist/array/zipWith.d.ts +5 -0
- package/dist/array/zipWith.mjs +13 -8
- package/dist/browser.global.js +2 -0
- package/dist/browser.global.js.map +1 -0
- package/dist/compat/_internal/getSymbols.mjs +6 -0
- package/dist/compat/_internal/getTag.mjs +8 -0
- package/dist/compat/_internal/identity.mjs +5 -0
- package/dist/compat/_internal/isArrayMatch.mjs +24 -0
- package/dist/compat/_internal/isDeepKey.mjs +15 -0
- package/dist/compat/_internal/isIndex.mjs +16 -0
- package/dist/compat/_internal/isMapMatch.mjs +18 -0
- package/dist/compat/_internal/isSetMatch.mjs +13 -0
- package/dist/compat/_internal/tags.mjs +28 -0
- package/dist/compat/_internal/toPath.mjs +40 -0
- package/dist/compat/array/chunk.d.mts +26 -0
- package/dist/compat/array/chunk.d.ts +26 -0
- package/dist/compat/array/chunk.mjs +11 -0
- package/dist/compat/array/concat.d.mts +30 -0
- package/dist/compat/array/concat.d.ts +30 -0
- package/dist/compat/array/concat.mjs +7 -0
- package/dist/compat/array/difference.d.mts +3 -0
- package/dist/compat/array/difference.d.ts +3 -0
- package/dist/compat/array/difference.mjs +10 -0
- package/dist/compat/array/fill.d.mts +33 -0
- package/dist/compat/array/fill.d.ts +33 -0
- package/dist/compat/array/fill.mjs +15 -0
- package/dist/compat/array/flatten.d.mts +19 -0
- package/dist/compat/array/flatten.d.ts +19 -0
- package/dist/compat/array/flatten.mjs +29 -0
- package/dist/compat/array/flattenDeep.d.mts +25 -0
- package/dist/compat/array/flattenDeep.d.ts +25 -0
- package/dist/compat/array/flattenDeep.mjs +7 -0
- package/dist/compat/array/flattenDepth.d.mts +19 -0
- package/dist/compat/array/flattenDepth.d.ts +19 -0
- package/dist/compat/array/flattenDepth.mjs +7 -0
- package/dist/compat/array/size.d.mts +39 -0
- package/dist/compat/array/size.d.ts +39 -0
- package/dist/compat/array/size.mjs +13 -0
- package/dist/compat/array/zipObjectDeep.d.mts +37 -0
- package/dist/compat/array/zipObjectDeep.d.ts +37 -0
- package/dist/compat/array/zipObjectDeep.mjs +16 -0
- package/dist/compat/function/ary.d.mts +11 -0
- package/dist/compat/function/ary.d.ts +11 -0
- package/dist/compat/function/ary.mjs +13 -0
- package/dist/compat/function/bind.d.mts +32 -0
- package/dist/compat/function/bind.d.ts +32 -0
- package/dist/compat/function/bind.mjs +27 -0
- package/dist/compat/index.d.mts +37 -472
- package/dist/compat/index.d.ts +37 -472
- package/dist/compat/index.js +513 -1333
- package/dist/compat/index.mjs +121 -391
- package/dist/compat/math/max.d.mts +19 -0
- package/dist/compat/math/max.d.ts +19 -0
- package/dist/compat/math/max.mjs +13 -0
- package/dist/compat/math/min.d.mts +19 -0
- package/dist/compat/math/min.d.ts +19 -0
- package/dist/compat/math/min.mjs +13 -0
- package/dist/compat/object/get.d.mts +247 -0
- package/dist/compat/object/get.d.ts +247 -0
- package/dist/compat/object/get.mjs +33 -0
- package/dist/compat/object/get.types.d.mts +9 -0
- package/dist/compat/object/get.types.d.ts +9 -0
- package/dist/compat/object/mapKeys.d.mts +39 -0
- package/dist/compat/object/mapKeys.d.ts +39 -0
- package/dist/compat/object/mapKeys.mjs +20 -0
- package/dist/compat/object/mapValues.d.mts +40 -0
- package/dist/compat/object/mapValues.d.ts +40 -0
- package/dist/compat/object/mapValues.mjs +20 -0
- package/dist/compat/object/property.d.mts +19 -0
- package/dist/compat/object/property.d.ts +19 -0
- package/dist/compat/object/property.mjs +9 -0
- package/dist/compat/object/set.d.mts +30 -0
- package/dist/compat/object/set.d.ts +30 -0
- package/dist/compat/object/set.mjs +24 -0
- package/dist/compat/predicate/isArguments.d.mts +23 -0
- package/dist/compat/predicate/isArguments.d.ts +23 -0
- package/dist/compat/predicate/isArguments.mjs +7 -0
- package/dist/compat/predicate/isArray.d.mts +23 -0
- package/dist/compat/predicate/isArray.d.ts +23 -0
- package/dist/compat/predicate/isArray.mjs +5 -0
- package/dist/compat/predicate/isArrayLike.d.mts +17 -0
- package/dist/compat/predicate/isArrayLike.d.ts +17 -0
- package/dist/compat/predicate/isArrayLike.mjs +8 -0
- package/dist/compat/predicate/isBoolean.d.mts +25 -0
- package/dist/compat/predicate/isBoolean.d.ts +25 -0
- package/dist/compat/predicate/isBoolean.mjs +13 -0
- package/dist/compat/predicate/isMatch.d.mts +31 -0
- package/dist/compat/predicate/isMatch.d.ts +31 -0
- package/dist/compat/predicate/isMatch.mjs +57 -0
- package/dist/compat/predicate/isObjectLike.d.mts +26 -0
- package/dist/compat/predicate/isObjectLike.d.ts +26 -0
- package/dist/compat/predicate/isObjectLike.mjs +5 -0
- package/dist/compat/predicate/isPlainObject.d.mts +25 -0
- package/dist/compat/predicate/isPlainObject.d.ts +25 -0
- package/dist/compat/predicate/isPlainObject.mjs +29 -0
- package/dist/compat/predicate/isTypedArray.d.mts +19 -0
- package/dist/compat/predicate/isTypedArray.d.ts +19 -0
- package/dist/compat/predicate/isTypedArray.mjs +7 -0
- package/dist/compat/predicate/matches.d.mts +27 -0
- package/dist/compat/predicate/matches.d.ts +27 -0
- package/dist/compat/predicate/matches.mjs +11 -0
- package/dist/compat/string/endsWith.d.mts +20 -0
- package/dist/compat/string/endsWith.d.ts +20 -0
- package/dist/compat/string/endsWith.mjs +5 -0
- package/dist/compat/string/padStart.d.mts +20 -0
- package/dist/compat/string/padStart.d.ts +20 -0
- package/dist/compat/string/padStart.mjs +5 -0
- package/dist/compat/string/startsWith.d.mts +20 -0
- package/dist/compat/string/startsWith.d.ts +20 -0
- package/dist/compat/string/startsWith.mjs +5 -0
- package/dist/error/AbortError.mjs +8 -8
- package/dist/error/TimeoutError.mjs +8 -8
- package/dist/function/after.d.mts +31 -0
- package/dist/function/after.d.ts +31 -0
- package/dist/function/after.mjs +14 -0
- package/dist/function/ary.d.mts +12 -0
- package/dist/function/ary.d.ts +12 -0
- package/dist/function/ary.mjs +7 -0
- package/dist/function/before.d.mts +31 -0
- package/dist/function/before.d.ts +31 -0
- package/dist/function/before.mjs +14 -0
- package/dist/function/debounce.mjs +28 -8
- package/dist/function/index.d.mts +4 -0
- package/dist/function/index.d.ts +4 -0
- package/dist/function/index.js +93 -88
- package/dist/function/index.mjs +9 -25
- package/dist/function/negate.mjs +5 -8
- package/dist/function/noop.mjs +3 -8
- package/dist/function/once.mjs +15 -8
- package/dist/function/throttle.mjs +13 -8
- package/dist/function/unary.d.mts +10 -0
- package/dist/function/unary.d.ts +10 -0
- package/dist/function/unary.mjs +7 -0
- package/dist/index.d.mts +12 -0
- package/dist/index.d.ts +12 -0
- package/dist/index.js +120 -1210
- package/dist/index.mjs +102 -375
- package/dist/math/clamp.mjs +8 -8
- package/dist/math/inRange.mjs +12 -8
- package/dist/math/index.js +58 -115
- package/dist/math/index.mjs +10 -45
- package/dist/math/mean.mjs +7 -9
- package/dist/math/meanBy.mjs +8 -10
- package/dist/math/random.mjs +12 -8
- package/dist/math/randomInt.mjs +7 -9
- package/dist/math/range.mjs +20 -8
- package/dist/math/round.mjs +9 -8
- package/dist/math/sum.mjs +9 -8
- package/dist/math/sumBy.mjs +8 -9
- package/dist/object/clone.mjs +39 -8
- package/dist/object/cloneDeep.d.mts +49 -0
- package/dist/object/cloneDeep.d.ts +49 -0
- package/dist/object/cloneDeep.mjs +113 -0
- package/dist/object/flattenObject.mjs +28 -9
- package/dist/object/index.d.mts +3 -0
- package/dist/object/index.d.ts +3 -0
- package/dist/object/index.js +230 -165
- package/dist/object/index.mjs +10 -34
- package/dist/object/invert.mjs +12 -8
- package/dist/object/mapKeys.d.mts +21 -0
- package/dist/object/mapKeys.d.ts +21 -0
- package/dist/object/mapKeys.mjs +12 -0
- package/dist/object/mapValues.d.mts +21 -0
- package/dist/object/mapValues.d.ts +21 -0
- package/dist/object/mapValues.mjs +12 -0
- package/dist/object/omit.mjs +9 -8
- package/dist/object/omitBy.mjs +12 -8
- package/dist/object/pick.mjs +9 -8
- package/dist/object/pickBy.mjs +12 -8
- package/dist/predicate/index.d.mts +4 -0
- package/dist/predicate/index.d.ts +4 -0
- package/dist/predicate/index.js +17 -126
- package/dist/predicate/index.mjs +11 -35
- package/dist/predicate/isBoolean.d.mts +25 -0
- package/dist/predicate/isBoolean.d.ts +25 -0
- package/dist/predicate/isBoolean.mjs +5 -0
- package/dist/predicate/isEqual.d.mts +1 -1
- package/dist/predicate/isEqual.d.ts +1 -1
- package/dist/predicate/isEqual.mjs +177 -10
- package/dist/predicate/isFunction.d.mts +16 -0
- package/dist/predicate/isFunction.d.ts +16 -0
- package/dist/predicate/isFunction.mjs +5 -0
- package/dist/predicate/isLength.d.mts +21 -0
- package/dist/predicate/isLength.d.ts +21 -0
- package/dist/predicate/isLength.mjs +5 -8
- package/dist/predicate/isNil.mjs +5 -8
- package/dist/predicate/isNotNil.mjs +5 -8
- package/dist/predicate/isNull.mjs +5 -8
- package/dist/predicate/isPlainObject.mjs +21 -8
- package/dist/predicate/isPrimitive.d.mts +17 -0
- package/dist/predicate/isPrimitive.d.ts +17 -0
- package/dist/predicate/isPrimitive.mjs +5 -0
- package/dist/predicate/isTypedArray.d.mts +19 -0
- package/dist/predicate/isTypedArray.d.ts +19 -0
- package/dist/predicate/isTypedArray.mjs +15 -0
- package/dist/predicate/isUndefined.mjs +5 -8
- package/dist/promise/delay.mjs +20 -9
- package/dist/promise/index.js +5 -96
- package/dist/promise/index.mjs +2 -16
- package/dist/promise/timeout.mjs +9 -11
- package/dist/promise/withTimeout.mjs +7 -12
- package/dist/string/_internal/getWords.mjs +6 -0
- package/dist/string/camelCase.mjs +13 -10
- package/dist/string/capitalize.mjs +4 -7
- package/dist/string/index.js +41 -78
- package/dist/string/index.mjs +6 -30
- package/dist/string/kebabCase.mjs +7 -8
- package/dist/string/lowerCase.mjs +7 -8
- package/dist/string/snakeCase.mjs +7 -8
- package/dist/string/startCase.mjs +20 -9
- package/package.json +13 -4
- package/dist/array/chunk.js +0 -43
- package/dist/array/chunk.js.map +0 -1
- package/dist/array/chunk.mjs.map +0 -1
- package/dist/array/compact.js +0 -39
- package/dist/array/compact.js.map +0 -1
- package/dist/array/compact.mjs.map +0 -1
- package/dist/array/countBy.js +0 -39
- package/dist/array/countBy.js.map +0 -1
- package/dist/array/countBy.mjs.map +0 -1
- package/dist/array/difference.js +0 -34
- package/dist/array/difference.js.map +0 -1
- package/dist/array/difference.mjs.map +0 -1
- package/dist/array/differenceBy.js +0 -36
- package/dist/array/differenceBy.js.map +0 -1
- package/dist/array/differenceBy.mjs.map +0 -1
- package/dist/array/differenceWith.js +0 -37
- package/dist/array/differenceWith.js.map +0 -1
- package/dist/array/differenceWith.mjs.map +0 -1
- package/dist/array/drop.js +0 -34
- package/dist/array/drop.js.map +0 -1
- package/dist/array/drop.mjs.map +0 -1
- package/dist/array/dropRight.js +0 -37
- package/dist/array/dropRight.js.map +0 -1
- package/dist/array/dropRight.mjs.map +0 -1
- package/dist/array/dropRightWhile.js +0 -38
- package/dist/array/dropRightWhile.js.map +0 -1
- package/dist/array/dropRightWhile.mjs.map +0 -1
- package/dist/array/dropWhile.js +0 -37
- package/dist/array/dropWhile.js.map +0 -1
- package/dist/array/dropWhile.mjs.map +0 -1
- package/dist/array/fill.js +0 -39
- package/dist/array/fill.js.map +0 -1
- package/dist/array/fill.mjs.map +0 -1
- package/dist/array/flatMap.js +0 -52
- package/dist/array/flatMap.js.map +0 -1
- package/dist/array/flatMap.mjs.map +0 -1
- package/dist/array/flatten.js +0 -45
- package/dist/array/flatten.js.map +0 -1
- package/dist/array/flatten.mjs.map +0 -1
- package/dist/array/flattenDeep.js +0 -52
- package/dist/array/flattenDeep.js.map +0 -1
- package/dist/array/flattenDeep.mjs.map +0 -1
- package/dist/array/forEachRight.js +0 -36
- package/dist/array/forEachRight.js.map +0 -1
- package/dist/array/forEachRight.mjs.map +0 -1
- package/dist/array/groupBy.js +0 -41
- package/dist/array/groupBy.js.map +0 -1
- package/dist/array/groupBy.mjs.map +0 -1
- package/dist/array/head.js +0 -33
- package/dist/array/head.js.map +0 -1
- package/dist/array/head.mjs.map +0 -1
- package/dist/array/index.js.map +0 -1
- package/dist/array/index.mjs.map +0 -1
- package/dist/array/initial.js +0 -36
- package/dist/array/initial.js.map +0 -1
- package/dist/array/initial.mjs.map +0 -1
- package/dist/array/intersection.js +0 -36
- package/dist/array/intersection.js.map +0 -1
- package/dist/array/intersection.mjs.map +0 -1
- package/dist/array/intersectionBy.js +0 -34
- package/dist/array/intersectionBy.js.map +0 -1
- package/dist/array/intersectionBy.mjs.map +0 -1
- package/dist/array/intersectionWith.js +0 -37
- package/dist/array/intersectionWith.js.map +0 -1
- package/dist/array/intersectionWith.mjs.map +0 -1
- package/dist/array/keyBy.js +0 -38
- package/dist/array/keyBy.js.map +0 -1
- package/dist/array/keyBy.mjs.map +0 -1
- package/dist/array/last.js +0 -33
- package/dist/array/last.js.map +0 -1
- package/dist/array/last.mjs.map +0 -1
- package/dist/array/maxBy.js +0 -42
- package/dist/array/maxBy.js.map +0 -1
- package/dist/array/maxBy.mjs.map +0 -1
- package/dist/array/minBy.js +0 -42
- package/dist/array/minBy.js.map +0 -1
- package/dist/array/minBy.mjs.map +0 -1
- package/dist/array/orderBy.js +0 -53
- package/dist/array/orderBy.js.map +0 -1
- package/dist/array/orderBy.mjs.map +0 -1
- package/dist/array/partition.js +0 -42
- package/dist/array/partition.js.map +0 -1
- package/dist/array/partition.mjs.map +0 -1
- package/dist/array/sample.js +0 -34
- package/dist/array/sample.js.map +0 -1
- package/dist/array/sample.mjs.map +0 -1
- package/dist/array/sampleSize.js +0 -65
- package/dist/array/sampleSize.js.map +0 -1
- package/dist/array/sampleSize.mjs.map +0 -1
- package/dist/array/shuffle.js +0 -38
- package/dist/array/shuffle.js.map +0 -1
- package/dist/array/shuffle.mjs.map +0 -1
- package/dist/array/tail.js +0 -41
- package/dist/array/tail.js.map +0 -1
- package/dist/array/tail.mjs.map +0 -1
- package/dist/array/take.js +0 -33
- package/dist/array/take.js.map +0 -1
- package/dist/array/take.mjs.map +0 -1
- package/dist/array/takeRight.js +0 -36
- package/dist/array/takeRight.js.map +0 -1
- package/dist/array/takeRight.mjs.map +0 -1
- package/dist/array/takeRightWhile.js +0 -38
- package/dist/array/takeRightWhile.js.map +0 -1
- package/dist/array/takeRightWhile.mjs.map +0 -1
- package/dist/array/takeWhile.js +0 -40
- package/dist/array/takeWhile.js.map +0 -1
- package/dist/array/takeWhile.mjs.map +0 -1
- package/dist/array/toFilled.js +0 -40
- package/dist/array/toFilled.js.map +0 -1
- package/dist/array/toFilled.mjs.map +0 -1
- package/dist/array/union.js +0 -40
- package/dist/array/union.js.map +0 -1
- package/dist/array/union.mjs.map +0 -1
- package/dist/array/unionBy.js +0 -40
- package/dist/array/unionBy.js.map +0 -1
- package/dist/array/unionBy.mjs.map +0 -1
- package/dist/array/unionWith.js +0 -47
- package/dist/array/unionWith.js.map +0 -1
- package/dist/array/unionWith.mjs.map +0 -1
- package/dist/array/uniq.js +0 -33
- package/dist/array/uniq.js.map +0 -1
- package/dist/array/uniq.mjs.map +0 -1
- package/dist/array/uniqBy.js +0 -40
- package/dist/array/uniqBy.js.map +0 -1
- package/dist/array/uniqBy.mjs.map +0 -1
- package/dist/array/uniqWith.js +0 -40
- package/dist/array/uniqWith.js.map +0 -1
- package/dist/array/uniqWith.mjs.map +0 -1
- package/dist/array/unzip.js +0 -46
- package/dist/array/unzip.js.map +0 -1
- package/dist/array/unzip.mjs.map +0 -1
- package/dist/array/unzipWith.js +0 -42
- package/dist/array/unzipWith.js.map +0 -1
- package/dist/array/unzipWith.mjs.map +0 -1
- package/dist/array/without.js +0 -34
- package/dist/array/without.js.map +0 -1
- package/dist/array/without.mjs.map +0 -1
- package/dist/array/xor.js +0 -59
- package/dist/array/xor.js.map +0 -1
- package/dist/array/xor.mjs.map +0 -1
- package/dist/array/xorBy.js +0 -63
- package/dist/array/xorBy.js.map +0 -1
- package/dist/array/xorBy.mjs.map +0 -1
- package/dist/array/xorWith.js +0 -72
- package/dist/array/xorWith.js.map +0 -1
- package/dist/array/xorWith.mjs.map +0 -1
- package/dist/array/zip.js +0 -42
- package/dist/array/zip.js.map +0 -1
- package/dist/array/zip.mjs.map +0 -1
- package/dist/array/zipObject.js +0 -37
- package/dist/array/zipObject.js.map +0 -1
- package/dist/array/zipObject.mjs.map +0 -1
- package/dist/array/zipWith.js +0 -41
- package/dist/array/zipWith.js.map +0 -1
- package/dist/array/zipWith.mjs.map +0 -1
- package/dist/browser.d.mts +0 -2
- package/dist/browser.d.ts +0 -2
- package/dist/browser.js +0 -1325
- package/dist/browser.js.map +0 -1
- package/dist/browser.mjs +0 -109
- package/dist/browser.mjs.map +0 -1
- package/dist/chunk-236H5JZJ.mjs +0 -1
- package/dist/chunk-236H5JZJ.mjs.map +0 -1
- package/dist/chunk-237HGSZS.mjs +0 -16
- package/dist/chunk-237HGSZS.mjs.map +0 -1
- package/dist/chunk-24FKGR6U.mjs +0 -47
- package/dist/chunk-24FKGR6U.mjs.map +0 -1
- package/dist/chunk-27QMXBLJ.mjs +0 -9
- package/dist/chunk-27QMXBLJ.mjs.map +0 -1
- package/dist/chunk-2IXFGSUA.mjs +0 -16
- package/dist/chunk-2IXFGSUA.mjs.map +0 -1
- package/dist/chunk-2KNLZB7V.mjs +0 -10
- package/dist/chunk-2KNLZB7V.mjs.map +0 -1
- package/dist/chunk-2SLTL4KL.mjs +0 -13
- package/dist/chunk-2SLTL4KL.mjs.map +0 -1
- package/dist/chunk-2ZCITDMK.mjs +0 -13
- package/dist/chunk-2ZCITDMK.mjs.map +0 -1
- package/dist/chunk-33MSBDC6.mjs +0 -21
- package/dist/chunk-33MSBDC6.mjs.map +0 -1
- package/dist/chunk-3EZAFZG3.mjs +0 -10
- package/dist/chunk-3EZAFZG3.mjs.map +0 -1
- package/dist/chunk-3IP4JVLL.mjs +0 -32
- package/dist/chunk-3IP4JVLL.mjs.map +0 -1
- package/dist/chunk-4KYXHZ4R.mjs +0 -17
- package/dist/chunk-4KYXHZ4R.mjs.map +0 -1
- package/dist/chunk-4OIZM4HS.mjs +0 -1
- package/dist/chunk-4OIZM4HS.mjs.map +0 -1
- package/dist/chunk-54TK5BIS.mjs +0 -1
- package/dist/chunk-54TK5BIS.mjs.map +0 -1
- package/dist/chunk-5ASRKEB4.mjs +0 -13
- package/dist/chunk-5ASRKEB4.mjs.map +0 -1
- package/dist/chunk-5IKVJGHO.mjs +0 -14
- package/dist/chunk-5IKVJGHO.mjs.map +0 -1
- package/dist/chunk-5L4VWRFX.mjs +0 -14
- package/dist/chunk-5L4VWRFX.mjs.map +0 -1
- package/dist/chunk-5PMKOZ2F.mjs +0 -13
- package/dist/chunk-5PMKOZ2F.mjs.map +0 -1
- package/dist/chunk-6CLH5YZ2.mjs +0 -16
- package/dist/chunk-6CLH5YZ2.mjs.map +0 -1
- package/dist/chunk-6GWEY5EL.mjs +0 -13
- package/dist/chunk-6GWEY5EL.mjs.map +0 -1
- package/dist/chunk-6NVQAHXP.mjs +0 -13
- package/dist/chunk-6NVQAHXP.mjs.map +0 -1
- package/dist/chunk-7B7W36UP.mjs +0 -29
- package/dist/chunk-7B7W36UP.mjs.map +0 -1
- package/dist/chunk-AIRSKN47.mjs +0 -9
- package/dist/chunk-AIRSKN47.mjs.map +0 -1
- package/dist/chunk-AJKZMN2V.mjs +0 -14
- package/dist/chunk-AJKZMN2V.mjs.map +0 -1
- package/dist/chunk-B4COTK4K.mjs +0 -16
- package/dist/chunk-B4COTK4K.mjs.map +0 -1
- package/dist/chunk-B645AYL4.mjs +0 -1
- package/dist/chunk-B645AYL4.mjs.map +0 -1
- package/dist/chunk-BCTYOXT7.mjs +0 -16
- package/dist/chunk-BCTYOXT7.mjs.map +0 -1
- package/dist/chunk-BH6HLGBA.mjs +0 -16
- package/dist/chunk-BH6HLGBA.mjs.map +0 -1
- package/dist/chunk-BJWAMCFH.mjs +0 -598
- package/dist/chunk-BJWAMCFH.mjs.map +0 -1
- package/dist/chunk-BMRTZMRE.mjs +0 -9
- package/dist/chunk-BMRTZMRE.mjs.map +0 -1
- package/dist/chunk-BOOQBJN2.mjs +0 -9
- package/dist/chunk-BOOQBJN2.mjs.map +0 -1
- package/dist/chunk-CMBC4MXG.mjs +0 -19
- package/dist/chunk-CMBC4MXG.mjs.map +0 -1
- package/dist/chunk-CRSKT4WW.mjs +0 -15
- package/dist/chunk-CRSKT4WW.mjs.map +0 -1
- package/dist/chunk-CVVZHOJX.mjs +0 -22
- package/dist/chunk-CVVZHOJX.mjs.map +0 -1
- package/dist/chunk-DDH7K4QM.mjs +0 -1
- package/dist/chunk-DDH7K4QM.mjs.map +0 -1
- package/dist/chunk-DN3NOZ3H.mjs +0 -18
- package/dist/chunk-DN3NOZ3H.mjs.map +0 -1
- package/dist/chunk-DPH2KE6O.mjs +0 -24
- package/dist/chunk-DPH2KE6O.mjs.map +0 -1
- package/dist/chunk-DTJJIMKJ.mjs +0 -15
- package/dist/chunk-DTJJIMKJ.mjs.map +0 -1
- package/dist/chunk-DVK2N4KC.mjs +0 -9
- package/dist/chunk-DVK2N4KC.mjs.map +0 -1
- package/dist/chunk-DXB7EZUQ.mjs +0 -12
- package/dist/chunk-DXB7EZUQ.mjs.map +0 -1
- package/dist/chunk-E6C5EZQA.mjs +0 -19
- package/dist/chunk-E6C5EZQA.mjs.map +0 -1
- package/dist/chunk-E6E4RZLN.mjs +0 -17
- package/dist/chunk-E6E4RZLN.mjs.map +0 -1
- package/dist/chunk-EHSKB6DF.mjs +0 -26
- package/dist/chunk-EHSKB6DF.mjs.map +0 -1
- package/dist/chunk-EYYZQFOP.mjs +0 -14
- package/dist/chunk-EYYZQFOP.mjs.map +0 -1
- package/dist/chunk-F3WCQQET.mjs +0 -14
- package/dist/chunk-F3WCQQET.mjs.map +0 -1
- package/dist/chunk-F47GLYUU.mjs +0 -1
- package/dist/chunk-F47GLYUU.mjs.map +0 -1
- package/dist/chunk-FUS75PJ7.mjs +0 -1
- package/dist/chunk-FUS75PJ7.mjs.map +0 -1
- package/dist/chunk-FVVSE2F2.mjs +0 -12
- package/dist/chunk-FVVSE2F2.mjs.map +0 -1
- package/dist/chunk-G7UQ5PUR.mjs +0 -14
- package/dist/chunk-G7UQ5PUR.mjs.map +0 -1
- package/dist/chunk-GIWAOOFY.mjs +0 -13
- package/dist/chunk-GIWAOOFY.mjs.map +0 -1
- package/dist/chunk-HM2JT2RX.mjs +0 -9
- package/dist/chunk-HM2JT2RX.mjs.map +0 -1
- package/dist/chunk-HPFDYUGP.mjs +0 -13
- package/dist/chunk-HPFDYUGP.mjs.map +0 -1
- package/dist/chunk-IDCUZVJL.mjs +0 -18
- package/dist/chunk-IDCUZVJL.mjs.map +0 -1
- package/dist/chunk-IEA53J7P.mjs +0 -12
- package/dist/chunk-IEA53J7P.mjs.map +0 -1
- package/dist/chunk-IFNXROZR.mjs +0 -18
- package/dist/chunk-IFNXROZR.mjs.map +0 -1
- package/dist/chunk-IIDZ3KAJ.mjs +0 -18
- package/dist/chunk-IIDZ3KAJ.mjs.map +0 -1
- package/dist/chunk-IJD7FE2Z.mjs +0 -18
- package/dist/chunk-IJD7FE2Z.mjs.map +0 -1
- package/dist/chunk-IQLKIDXF.mjs +0 -12
- package/dist/chunk-IQLKIDXF.mjs.map +0 -1
- package/dist/chunk-JPUKH67K.mjs +0 -10
- package/dist/chunk-JPUKH67K.mjs.map +0 -1
- package/dist/chunk-JYSV56US.mjs +0 -41
- package/dist/chunk-JYSV56US.mjs.map +0 -1
- package/dist/chunk-KIOYQRMQ.mjs +0 -12
- package/dist/chunk-KIOYQRMQ.mjs.map +0 -1
- package/dist/chunk-KPBQ7OUY.mjs +0 -9
- package/dist/chunk-KPBQ7OUY.mjs.map +0 -1
- package/dist/chunk-L7FQX5MN.mjs +0 -19
- package/dist/chunk-L7FQX5MN.mjs.map +0 -1
- package/dist/chunk-LJ2C6MVP.mjs +0 -13
- package/dist/chunk-LJ2C6MVP.mjs.map +0 -1
- package/dist/chunk-LKXCOLNY.mjs +0 -8
- package/dist/chunk-LKXCOLNY.mjs.map +0 -1
- package/dist/chunk-LVWX5B43.mjs +0 -12
- package/dist/chunk-LVWX5B43.mjs.map +0 -1
- package/dist/chunk-M7SBBYV2.mjs +0 -14
- package/dist/chunk-M7SBBYV2.mjs.map +0 -1
- package/dist/chunk-ME352XO7.mjs +0 -9
- package/dist/chunk-ME352XO7.mjs.map +0 -1
- package/dist/chunk-MIGAC7F4.mjs +0 -25
- package/dist/chunk-MIGAC7F4.mjs.map +0 -1
- package/dist/chunk-ML727RRJ.mjs +0 -13
- package/dist/chunk-ML727RRJ.mjs.map +0 -1
- package/dist/chunk-MLCL773E.mjs +0 -12
- package/dist/chunk-MLCL773E.mjs.map +0 -1
- package/dist/chunk-MY4G7R3I.mjs +0 -14
- package/dist/chunk-MY4G7R3I.mjs.map +0 -1
- package/dist/chunk-NFS7RWWE.mjs +0 -16
- package/dist/chunk-NFS7RWWE.mjs.map +0 -1
- package/dist/chunk-NKLIE2OI.mjs +0 -1
- package/dist/chunk-NKLIE2OI.mjs.map +0 -1
- package/dist/chunk-NTLX2MPV.mjs +0 -14
- package/dist/chunk-NTLX2MPV.mjs.map +0 -1
- package/dist/chunk-O64NE2P4.mjs +0 -26
- package/dist/chunk-O64NE2P4.mjs.map +0 -1
- package/dist/chunk-O6UXZR3U.mjs +0 -10
- package/dist/chunk-O6UXZR3U.mjs.map +0 -1
- package/dist/chunk-OLX53VEF.mjs +0 -16
- package/dist/chunk-OLX53VEF.mjs.map +0 -1
- package/dist/chunk-OOKNBU4V.mjs +0 -18
- package/dist/chunk-OOKNBU4V.mjs.map +0 -1
- package/dist/chunk-OP4OAKQJ.mjs +0 -16
- package/dist/chunk-OP4OAKQJ.mjs.map +0 -1
- package/dist/chunk-OXZCMC5I.mjs +0 -13
- package/dist/chunk-OXZCMC5I.mjs.map +0 -1
- package/dist/chunk-PYEYV7BY.mjs +0 -10
- package/dist/chunk-PYEYV7BY.mjs.map +0 -1
- package/dist/chunk-Q47NGNXT.mjs +0 -21
- package/dist/chunk-Q47NGNXT.mjs.map +0 -1
- package/dist/chunk-QOJGMVVR.mjs +0 -17
- package/dist/chunk-QOJGMVVR.mjs.map +0 -1
- package/dist/chunk-QRSJBBFY.mjs +0 -21
- package/dist/chunk-QRSJBBFY.mjs.map +0 -1
- package/dist/chunk-QXTNZR7B.mjs +0 -25
- package/dist/chunk-QXTNZR7B.mjs.map +0 -1
- package/dist/chunk-R6QA7PLZ.mjs +0 -13
- package/dist/chunk-R6QA7PLZ.mjs.map +0 -1
- package/dist/chunk-SYWMYQYJ.mjs +0 -16
- package/dist/chunk-SYWMYQYJ.mjs.map +0 -1
- package/dist/chunk-TJ4Z5I7M.mjs +0 -17
- package/dist/chunk-TJ4Z5I7M.mjs.map +0 -1
- package/dist/chunk-U4JGKZ56.mjs +0 -41
- package/dist/chunk-U4JGKZ56.mjs.map +0 -1
- package/dist/chunk-U56ZOM7L.mjs +0 -9
- package/dist/chunk-U56ZOM7L.mjs.map +0 -1
- package/dist/chunk-UY76KTPE.mjs +0 -13
- package/dist/chunk-UY76KTPE.mjs.map +0 -1
- package/dist/chunk-UYZKMBDO.mjs +0 -22
- package/dist/chunk-UYZKMBDO.mjs.map +0 -1
- package/dist/chunk-VH2PV426.mjs +0 -9
- package/dist/chunk-VH2PV426.mjs.map +0 -1
- package/dist/chunk-WFZXCGEG.mjs +0 -17
- package/dist/chunk-WFZXCGEG.mjs.map +0 -1
- package/dist/chunk-WMM7TZLG.mjs +0 -9
- package/dist/chunk-WMM7TZLG.mjs.map +0 -1
- package/dist/chunk-WVQ7YVRK.mjs +0 -11
- package/dist/chunk-WVQ7YVRK.mjs.map +0 -1
- package/dist/chunk-XGQWTHW6.mjs +0 -34
- package/dist/chunk-XGQWTHW6.mjs.map +0 -1
- package/dist/chunk-XI7KRD2C.mjs +0 -13
- package/dist/chunk-XI7KRD2C.mjs.map +0 -1
- package/dist/chunk-XPSOKBRZ.mjs +0 -12
- package/dist/chunk-XPSOKBRZ.mjs.map +0 -1
- package/dist/chunk-XT74R35S.mjs +0 -1
- package/dist/chunk-XT74R35S.mjs.map +0 -1
- package/dist/chunk-Y5V7UAZZ.mjs +0 -21
- package/dist/chunk-Y5V7UAZZ.mjs.map +0 -1
- package/dist/chunk-YFN6KOC4.mjs +0 -15
- package/dist/chunk-YFN6KOC4.mjs.map +0 -1
- package/dist/compat/index.js.map +0 -1
- package/dist/compat/index.mjs.map +0 -1
- package/dist/error/AbortError.js +0 -36
- package/dist/error/AbortError.js.map +0 -1
- package/dist/error/AbortError.mjs.map +0 -1
- package/dist/error/TimeoutError.js +0 -36
- package/dist/error/TimeoutError.js.map +0 -1
- package/dist/error/TimeoutError.mjs.map +0 -1
- package/dist/error/index.d.mts +0 -2
- package/dist/error/index.d.ts +0 -2
- package/dist/error/index.js +0 -48
- package/dist/error/index.js.map +0 -1
- package/dist/error/index.mjs +0 -13
- package/dist/error/index.mjs.map +0 -1
- package/dist/function/debounce.js +0 -56
- package/dist/function/debounce.js.map +0 -1
- package/dist/function/debounce.mjs.map +0 -1
- package/dist/function/index.js.map +0 -1
- package/dist/function/index.mjs.map +0 -1
- package/dist/function/negate.js +0 -33
- package/dist/function/negate.js.map +0 -1
- package/dist/function/negate.mjs.map +0 -1
- package/dist/function/noop.js +0 -32
- package/dist/function/noop.js.map +0 -1
- package/dist/function/noop.mjs.map +0 -1
- package/dist/function/once.js +0 -43
- package/dist/function/once.js.map +0 -1
- package/dist/function/once.mjs.map +0 -1
- package/dist/function/throttle.js +0 -41
- package/dist/function/throttle.js.map +0 -1
- package/dist/function/throttle.mjs.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/index.mjs.map +0 -1
- package/dist/math/clamp.js +0 -36
- package/dist/math/clamp.js.map +0 -1
- package/dist/math/clamp.mjs.map +0 -1
- package/dist/math/inRange.js +0 -40
- package/dist/math/inRange.js.map +0 -1
- package/dist/math/inRange.mjs.map +0 -1
- package/dist/math/index.js.map +0 -1
- package/dist/math/index.mjs.map +0 -1
- package/dist/math/mean.js +0 -44
- package/dist/math/mean.js.map +0 -1
- package/dist/math/mean.mjs.map +0 -1
- package/dist/math/meanBy.js +0 -50
- package/dist/math/meanBy.js.map +0 -1
- package/dist/math/meanBy.mjs.map +0 -1
- package/dist/math/random.js +0 -40
- package/dist/math/random.js.map +0 -1
- package/dist/math/random.mjs.map +0 -1
- package/dist/math/randomInt.js +0 -47
- package/dist/math/randomInt.js.map +0 -1
- package/dist/math/randomInt.mjs.map +0 -1
- package/dist/math/range.js +0 -48
- package/dist/math/range.js.map +0 -1
- package/dist/math/range.mjs.map +0 -1
- package/dist/math/round.js +0 -37
- package/dist/math/round.js.map +0 -1
- package/dist/math/round.mjs.map +0 -1
- package/dist/math/sum.js +0 -37
- package/dist/math/sum.js.map +0 -1
- package/dist/math/sum.mjs.map +0 -1
- package/dist/math/sumBy.js +0 -45
- package/dist/math/sumBy.js.map +0 -1
- package/dist/math/sumBy.mjs.map +0 -1
- package/dist/object/clone.js +0 -65
- package/dist/object/clone.js.map +0 -1
- package/dist/object/clone.mjs.map +0 -1
- package/dist/object/flattenObject.js +0 -77
- package/dist/object/flattenObject.js.map +0 -1
- package/dist/object/flattenObject.mjs.map +0 -1
- package/dist/object/index.js.map +0 -1
- package/dist/object/index.mjs.map +0 -1
- package/dist/object/invert.js +0 -40
- package/dist/object/invert.js.map +0 -1
- package/dist/object/invert.mjs.map +0 -1
- package/dist/object/omit.js +0 -51
- package/dist/object/omit.js.map +0 -1
- package/dist/object/omit.mjs.map +0 -1
- package/dist/object/omitBy.js +0 -40
- package/dist/object/omitBy.js.map +0 -1
- package/dist/object/omitBy.mjs.map +0 -1
- package/dist/object/pick.js +0 -37
- package/dist/object/pick.js.map +0 -1
- package/dist/object/pick.mjs.map +0 -1
- package/dist/object/pickBy.js +0 -40
- package/dist/object/pickBy.js.map +0 -1
- package/dist/object/pickBy.mjs.map +0 -1
- package/dist/predicate/index.js.map +0 -1
- package/dist/predicate/index.mjs.map +0 -1
- package/dist/predicate/isEqual.js +0 -73
- package/dist/predicate/isEqual.js.map +0 -1
- package/dist/predicate/isEqual.mjs.map +0 -1
- package/dist/predicate/isLength.js +0 -33
- package/dist/predicate/isLength.js.map +0 -1
- package/dist/predicate/isLength.mjs.map +0 -1
- package/dist/predicate/isNil.js +0 -33
- package/dist/predicate/isNil.js.map +0 -1
- package/dist/predicate/isNil.mjs.map +0 -1
- package/dist/predicate/isNotNil.js +0 -33
- package/dist/predicate/isNotNil.js.map +0 -1
- package/dist/predicate/isNotNil.mjs.map +0 -1
- package/dist/predicate/isNull.js +0 -33
- package/dist/predicate/isNull.js.map +0 -1
- package/dist/predicate/isNull.mjs.map +0 -1
- package/dist/predicate/isPlainObject.js +0 -49
- package/dist/predicate/isPlainObject.js.map +0 -1
- package/dist/predicate/isPlainObject.mjs.map +0 -1
- package/dist/predicate/isUndefined.js +0 -33
- package/dist/predicate/isUndefined.js.map +0 -1
- package/dist/predicate/isUndefined.mjs.map +0 -1
- package/dist/promise/delay.js +0 -56
- package/dist/promise/delay.js.map +0 -1
- package/dist/promise/delay.mjs.map +0 -1
- package/dist/promise/index.js.map +0 -1
- package/dist/promise/index.mjs.map +0 -1
- package/dist/promise/timeout.d.mts +0 -10
- package/dist/promise/timeout.d.ts +0 -10
- package/dist/promise/timeout.js +0 -92
- package/dist/promise/timeout.js.map +0 -1
- package/dist/promise/timeout.mjs.map +0 -1
- package/dist/promise/withTimeout.js +0 -99
- package/dist/promise/withTimeout.js.map +0 -1
- package/dist/promise/withTimeout.mjs.map +0 -1
- package/dist/string/camelCase.js +0 -52
- package/dist/string/camelCase.js.map +0 -1
- package/dist/string/camelCase.mjs.map +0 -1
- package/dist/string/capitalize.js +0 -33
- package/dist/string/capitalize.js.map +0 -1
- package/dist/string/capitalize.mjs.map +0 -1
- package/dist/string/index.js.map +0 -1
- package/dist/string/index.mjs.map +0 -1
- package/dist/string/kebabCase.js +0 -43
- package/dist/string/kebabCase.js.map +0 -1
- package/dist/string/kebabCase.mjs.map +0 -1
- package/dist/string/lowerCase.js +0 -43
- package/dist/string/lowerCase.js.map +0 -1
- package/dist/string/lowerCase.mjs.map +0 -1
- package/dist/string/snakeCase.js +0 -43
- package/dist/string/snakeCase.js.map +0 -1
- package/dist/string/snakeCase.mjs.map +0 -1
- package/dist/string/startCase.js +0 -54
- package/dist/string/startCase.js.map +0 -1
- package/dist/string/startCase.mjs.map +0 -1
- package/umd/browser.global.js +0 -2
package/dist/compat/index.d.ts
CHANGED
|
@@ -6,10 +6,7 @@ export { drop } from '../array/drop.js';
|
|
|
6
6
|
export { dropRight } from '../array/dropRight.js';
|
|
7
7
|
export { dropRightWhile } from '../array/dropRightWhile.js';
|
|
8
8
|
export { dropWhile } from '../array/dropWhile.js';
|
|
9
|
-
export { fill } from '../array/fill.js';
|
|
10
9
|
export { flatMap } from '../array/flatMap.js';
|
|
11
|
-
export { flatten } from '../array/flatten.js';
|
|
12
|
-
export { flattenDeep } from '../array/flattenDeep.js';
|
|
13
10
|
export { forEachRight } from '../array/forEachRight.js';
|
|
14
11
|
export { groupBy } from '../array/groupBy.js';
|
|
15
12
|
export { intersection } from '../array/intersection.js';
|
|
@@ -43,17 +40,21 @@ export { zipObject } from '../array/zipObject.js';
|
|
|
43
40
|
export { zipWith } from '../array/zipWith.js';
|
|
44
41
|
export { without } from '../array/without.js';
|
|
45
42
|
export { head as first, head } from '../array/head.js';
|
|
43
|
+
export { isSubset } from '../array/isSubset.js';
|
|
46
44
|
export { tail } from '../array/tail.js';
|
|
47
45
|
export { toFilled } from '../array/toFilled.js';
|
|
48
46
|
export { last } from '../array/last.js';
|
|
49
47
|
export { initial } from '../array/initial.js';
|
|
50
48
|
export { AbortError } from '../error/AbortError.js';
|
|
51
49
|
export { TimeoutError } from '../error/TimeoutError.js';
|
|
50
|
+
export { before } from '../function/before.js';
|
|
51
|
+
export { after } from '../function/after.js';
|
|
52
52
|
export { debounce } from '../function/debounce.js';
|
|
53
53
|
export { noop } from '../function/noop.js';
|
|
54
54
|
export { once } from '../function/once.js';
|
|
55
55
|
export { throttle } from '../function/throttle.js';
|
|
56
56
|
export { negate } from '../function/negate.js';
|
|
57
|
+
export { unary } from '../function/unary.js';
|
|
57
58
|
export { clamp } from '../math/clamp.js';
|
|
58
59
|
export { inRange } from '../math/inRange.js';
|
|
59
60
|
export { mean } from '../math/mean.js';
|
|
@@ -71,12 +72,15 @@ export { pickBy } from '../object/pickBy.js';
|
|
|
71
72
|
export { invert } from '../object/invert.js';
|
|
72
73
|
export { clone } from '../object/clone.js';
|
|
73
74
|
export { flattenObject } from '../object/flattenObject.js';
|
|
75
|
+
export { cloneDeep } from '../object/cloneDeep.js';
|
|
74
76
|
export { isEqual } from '../predicate/isEqual.js';
|
|
75
77
|
export { isNil } from '../predicate/isNil.js';
|
|
76
78
|
export { isNotNil } from '../predicate/isNotNil.js';
|
|
77
79
|
export { isNull } from '../predicate/isNull.js';
|
|
78
80
|
export { isUndefined } from '../predicate/isUndefined.js';
|
|
79
81
|
export { isLength } from '../predicate/isLength.js';
|
|
82
|
+
export { isFunction } from '../predicate/isFunction.js';
|
|
83
|
+
export { isPrimitive } from '../predicate/isPrimitive.js';
|
|
80
84
|
export { delay } from '../promise/delay.js';
|
|
81
85
|
export { withTimeout } from '../promise/withTimeout.js';
|
|
82
86
|
export { camelCase } from '../string/camelCase.js';
|
|
@@ -85,472 +89,33 @@ export { kebabCase } from '../string/kebabCase.js';
|
|
|
85
89
|
export { lowerCase } from '../string/lowerCase.js';
|
|
86
90
|
export { startCase } from '../string/startCase.js';
|
|
87
91
|
export { capitalize } from '../string/capitalize.js';
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
* @param {...(T | readonly T[])} values - The values and/or arrays to concatenate.
|
|
119
|
-
* @returns {T[]} A new array containing all the input values.
|
|
120
|
-
*
|
|
121
|
-
* @example
|
|
122
|
-
* // Concatenate individual values
|
|
123
|
-
* concat(1, 2, 3);
|
|
124
|
-
* // returns [1, 2, 3]
|
|
125
|
-
*
|
|
126
|
-
* @example
|
|
127
|
-
* // Concatenate arrays of values
|
|
128
|
-
* concat([1, 2], [3, 4]);
|
|
129
|
-
* // returns [1, 2, 3, 4]
|
|
130
|
-
*
|
|
131
|
-
* @example
|
|
132
|
-
* // Concatenate a mix of individual values and arrays
|
|
133
|
-
* concat(1, [2, 3], 4);
|
|
134
|
-
* // returns [1, 2, 3, 4]
|
|
135
|
-
*
|
|
136
|
-
* @example
|
|
137
|
-
* // Concatenate nested arrays
|
|
138
|
-
* concat([1, [2, 3]], 4);
|
|
139
|
-
* // returns [1, [2, 3], 4]
|
|
140
|
-
*/
|
|
141
|
-
declare function concat<T>(...values: Array<T | readonly T[]>): T[];
|
|
142
|
-
|
|
143
|
-
declare function difference<T>(arr: readonly T[], ...values: Array<readonly T[]>): T[];
|
|
144
|
-
|
|
145
|
-
/**
|
|
146
|
-
* Creates a deeply nested object given arrays of paths and values.
|
|
147
|
-
*
|
|
148
|
-
* This function takes two arrays: one containing arrays of property paths, and the other containing corresponding values.
|
|
149
|
-
* It returns a new object where paths from the first array are used as key paths to set values, with corresponding elements from the second array as values.
|
|
150
|
-
* Paths can be dot-separated strings or arrays of property names.
|
|
151
|
-
*
|
|
152
|
-
* If the `keys` array is longer than the `values` array, the remaining keys will have `undefined` as their values.
|
|
153
|
-
*
|
|
154
|
-
* @template V - The type of elements in the array.
|
|
155
|
-
* @param {string[] | string[][]} keys - An array of property paths, each path can be a dot-separated string or an array of property names.
|
|
156
|
-
* @param {V[]} values - An array of values corresponding to the property paths.
|
|
157
|
-
* @returns {object} A new object composed of the given property paths and values.
|
|
158
|
-
*
|
|
159
|
-
* @example
|
|
160
|
-
* const paths = ['a.b.c', 'd.e.f'];
|
|
161
|
-
* const values = [1, 2];
|
|
162
|
-
* const result = zipObjectDeep(paths, values);
|
|
163
|
-
* // result will be { a: { b: { c: 1 } }, d: { e: { f: 2 } } }
|
|
164
|
-
*
|
|
165
|
-
* @example
|
|
166
|
-
* const paths = [['a', 'b', 'c'], ['d', 'e', 'f']];
|
|
167
|
-
* const values = [1, 2];
|
|
168
|
-
* const result = zipObjectDeep(paths, values);
|
|
169
|
-
* // result will be { a: { b: { c: 1 } }, d: { e: { f: 2 } } }
|
|
170
|
-
*
|
|
171
|
-
* @example
|
|
172
|
-
* const paths = ['a.b[0].c', 'a.b[1].d'];
|
|
173
|
-
* const values = [1, 2];
|
|
174
|
-
* const result = zipObjectDeep(paths, values);
|
|
175
|
-
* // result will be { 'a': { 'b': [{ 'c': 1 }, { 'd': 2 }] } }
|
|
176
|
-
*/
|
|
177
|
-
declare function zipObjectDeep<P extends string | number | symbol, V>(keys: P[], values: V[]): {
|
|
178
|
-
[K in P]: V;
|
|
179
|
-
};
|
|
180
|
-
|
|
181
|
-
/**
|
|
182
|
-
* See the definition of `@types/lodash`.
|
|
183
|
-
*/
|
|
184
|
-
type GetIndexedField<T, K> = K extends keyof T ? T[K] : K extends `${number}` ? 'length' extends keyof T ? number extends T['length'] ? number extends keyof T ? T[number] : undefined : undefined : undefined : undefined;
|
|
185
|
-
type FieldWithPossiblyUndefined<T, Key> = Get<Exclude<T, undefined>, Key> | Extract<T, undefined>;
|
|
186
|
-
type IndexedFieldWithPossiblyUndefined<T, Key> = GetIndexedField<Exclude<T, undefined>, Key> | Extract<T, undefined>;
|
|
187
|
-
type Get<T, P> = P extends `${infer Left}.${infer Right}` ? Left extends keyof Exclude<T, undefined> ? FieldWithPossiblyUndefined<Exclude<T, undefined>[Left], Right> | Extract<T, undefined> : Left extends `${infer FieldKey}[${infer IndexKey}]` ? FieldKey extends keyof T ? FieldWithPossiblyUndefined<IndexedFieldWithPossiblyUndefined<T[FieldKey], IndexKey>, Right> : undefined : undefined : P extends keyof T ? T[P] : P extends `${infer FieldKey}[${infer IndexKey}]` ? FieldKey extends keyof T ? IndexedFieldWithPossiblyUndefined<T[FieldKey], IndexKey> : undefined : IndexedFieldWithPossiblyUndefined<T, P>;
|
|
188
|
-
|
|
189
|
-
/**
|
|
190
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
191
|
-
*
|
|
192
|
-
* @template T - The type of the object.
|
|
193
|
-
* @template K - The type of the key in the object.
|
|
194
|
-
* @template D - The type of the default value.
|
|
195
|
-
*
|
|
196
|
-
* @param {T} object - The object to query.
|
|
197
|
-
* @param {K | [K]} path - The path of the property to get.
|
|
198
|
-
* @returns {T[K]} - Returns the resolved value.
|
|
199
|
-
*/
|
|
200
|
-
declare function get<T extends object, K extends keyof T>(object: T, path: K | [K]): T[K];
|
|
201
|
-
/**
|
|
202
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
203
|
-
*
|
|
204
|
-
* @template T - The type of the object.
|
|
205
|
-
* @template K - The type of the key in the object.
|
|
206
|
-
*
|
|
207
|
-
* @param {T | null | undefined} object - The object to query.
|
|
208
|
-
* @param {K | [K]} path - The path of the property to get.
|
|
209
|
-
* @returns {T[K] | undefined} - Returns the resolved value.
|
|
210
|
-
*/
|
|
211
|
-
declare function get<T extends object, K extends keyof T>(object: T | null | undefined, path: K | [K]): T[K] | undefined;
|
|
212
|
-
/**
|
|
213
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
214
|
-
*
|
|
215
|
-
* @template T - The type of the object.
|
|
216
|
-
* @template K - The type of the key in the object.
|
|
217
|
-
* @template D - The type of the default value.
|
|
218
|
-
*
|
|
219
|
-
* @param {T | null | undefined} object - The object to query.
|
|
220
|
-
* @param {K | [K]} path - The path of the property to get.
|
|
221
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
222
|
-
* @returns {Exclude<T[K], undefined> | D} - Returns the resolved value.
|
|
223
|
-
*/
|
|
224
|
-
declare function get<T extends object, K extends keyof T, D>(object: T | null | undefined, path: K | [K], defaultValue: D): Exclude<T[K], undefined> | D;
|
|
225
|
-
/**
|
|
226
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
227
|
-
*
|
|
228
|
-
* @template T - The type of the object.
|
|
229
|
-
* @template K1 - The type of the first key in the object.
|
|
230
|
-
* @template K2 - The type of the second key in the object.
|
|
231
|
-
*
|
|
232
|
-
* @param {T} object - The object to query.
|
|
233
|
-
* @param {[K1, K2]} path - The path of the property to get.
|
|
234
|
-
* @returns {T[K1][K2]} - Returns the resolved value.
|
|
235
|
-
*/
|
|
236
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1]>(object: T, path: [K1, K2]): T[K1][K2];
|
|
237
|
-
/**
|
|
238
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
239
|
-
*
|
|
240
|
-
* @template T - The type of the object.
|
|
241
|
-
* @template K1 - The type of the first key in the object.
|
|
242
|
-
* @template K2 - The type of the second key in the object.
|
|
243
|
-
*
|
|
244
|
-
* @param {T | null | undefined} object - The object to query.
|
|
245
|
-
* @param {[K1, K2]} path - The path of the property to get.
|
|
246
|
-
* @returns {T[K1][K2] | undefined} - Returns the resolved value.
|
|
247
|
-
*/
|
|
248
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1]>(object: T | null | undefined, path: [K1, K2]): T[K1][K2] | undefined;
|
|
249
|
-
/**
|
|
250
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
251
|
-
*
|
|
252
|
-
* @template T - The type of the object.
|
|
253
|
-
* @template K1 - The type of the first key in the object.
|
|
254
|
-
* @template K2 - The type of the second key in the object.
|
|
255
|
-
* @template D - The type of the default value.
|
|
256
|
-
*
|
|
257
|
-
* @param {T | null | undefined} object - The object to query.
|
|
258
|
-
* @param {[K1, K2]} path - The path of the property to get.
|
|
259
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
260
|
-
* @returns {Exclude<T[K1][K2], undefined> | D} - Returns the resolved value.
|
|
261
|
-
*/
|
|
262
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], D>(object: T | null | undefined, path: [K1, K2], defaultValue: D): Exclude<T[K1][K2], undefined> | D;
|
|
263
|
-
/**
|
|
264
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
265
|
-
*
|
|
266
|
-
* @template T - The type of the object.
|
|
267
|
-
* @template K1 - The type of the first key in the object.
|
|
268
|
-
* @template K2 - The type of the second key in the object.
|
|
269
|
-
* @template K3 - The type of the third key in the object.
|
|
270
|
-
*
|
|
271
|
-
* @param {T} object - The object to query.
|
|
272
|
-
* @param {[K1, K2, K3]} path - The path of the property to get.
|
|
273
|
-
* @returns {T[K1][K2][K3]} - Returns the resolved value.
|
|
274
|
-
*/
|
|
275
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2]>(object: T, path: [K1, K2, K3]): T[K1][K2][K3];
|
|
276
|
-
/**
|
|
277
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
278
|
-
*
|
|
279
|
-
* @template T - The type of the object.
|
|
280
|
-
* @template K1 - The type of the first key in the object.
|
|
281
|
-
* @template K2 - The type of the second key in the object.
|
|
282
|
-
* @template K3 - The type of the third key in the object.
|
|
283
|
-
*
|
|
284
|
-
* @param {T | null | undefined} object - The object to query.
|
|
285
|
-
* @param {[K1, K2, K3]} path - The path of the property to get.
|
|
286
|
-
* @returns {T[K1][K2][K3] | undefined} - Returns the resolved value.
|
|
287
|
-
*/
|
|
288
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2]>(object: T | null | undefined, path: [K1, K2, K3]): T[K1][K2][K3] | undefined;
|
|
289
|
-
/**
|
|
290
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
291
|
-
*
|
|
292
|
-
* @template T - The type of the object.
|
|
293
|
-
* @template K1 - The type of the first key in the object.
|
|
294
|
-
* @template K2 - The type of the second key in the object.
|
|
295
|
-
* @template K3 - The type of the third key in the object.
|
|
296
|
-
* @template D - The type of the default value.
|
|
297
|
-
*
|
|
298
|
-
* @param {T | null | undefined} object - The object to query.
|
|
299
|
-
* @param {[K1, K2, K3]} path - The path of the property to get.
|
|
300
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
301
|
-
* @returns {Exclude<T[K1][K2][K3], undefined> | D} - Returns the resolved value.
|
|
302
|
-
*/
|
|
303
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], D>(object: T | null | undefined, path: [K1, K2, K3], defaultValue: D): Exclude<T[K1][K2][K3], undefined> | D;
|
|
304
|
-
/**
|
|
305
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
306
|
-
*
|
|
307
|
-
* @template T - The type of the object.
|
|
308
|
-
* @template K1 - The type of the first key in the object.
|
|
309
|
-
* @template K2 - The type of the second key in the object.
|
|
310
|
-
* @template K3 - The type of the third key in the object.
|
|
311
|
-
* @template K4 - The type of the fourth key in the object.
|
|
312
|
-
*
|
|
313
|
-
* @param {T} object - The object to query.
|
|
314
|
-
* @param {[K1, K2, K3, K4]} path - The path of the property to get.
|
|
315
|
-
* @returns {T[K1][K2][K3][K4]} - Returns the resolved value.
|
|
316
|
-
*/
|
|
317
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], K4 extends keyof T[K1][K2][K3]>(object: T, path: [K1, K2, K3, K4]): T[K1][K2][K3][K4];
|
|
318
|
-
/**
|
|
319
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
320
|
-
*
|
|
321
|
-
* @template T - The type of the object.
|
|
322
|
-
* @template K1 - The type of the first key in the object.
|
|
323
|
-
* @template K2 - The type of the second key in the object.
|
|
324
|
-
* @template K3 - The type of the third key in the object.
|
|
325
|
-
* @template K4 - The type of the fourth key in the object.
|
|
326
|
-
*
|
|
327
|
-
* @param {T | null | undefined} object - The object to query.
|
|
328
|
-
* @param {[K1, K2, K3, K4]} path - The path of the property to get.
|
|
329
|
-
* @returns {T[K1][K2][K3][K4] | undefined} - Returns the resolved value.
|
|
330
|
-
*/
|
|
331
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], K4 extends keyof T[K1][K2][K3]>(object: T | null | undefined, path: [K1, K2, K3, K4]): T[K1][K2][K3][K4] | undefined;
|
|
332
|
-
/**
|
|
333
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
334
|
-
*
|
|
335
|
-
* @template T - The type of the object.
|
|
336
|
-
* @template K1 - The type of the first key in the object.
|
|
337
|
-
* @template K2 - The type of the second key in the object.
|
|
338
|
-
* @template K3 - The type of the third key in the object.
|
|
339
|
-
* @template K4 - The type of the fourth key in the object.
|
|
340
|
-
* @template D - The type of the default value.
|
|
341
|
-
*
|
|
342
|
-
* @param {T | null | undefined} object - The object to query.
|
|
343
|
-
* @param {[K1, K2, K3, K4]} path - The path of the property to get.
|
|
344
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
345
|
-
* @returns {Exclude<T[K1][K2][K3][K4], undefined> | D} - Returns the resolved value.
|
|
346
|
-
*/
|
|
347
|
-
declare function get<T extends object, K1 extends keyof T, K2 extends keyof T[K1], K3 extends keyof T[K1][K2], K4 extends keyof T[K1][K2][K3], D>(object: T | null | undefined, path: [K1, K2, K3, K4], defaultValue: D): Exclude<T[K1][K2][K3][K4], undefined> | D;
|
|
348
|
-
/**
|
|
349
|
-
* Retrieves the value at a given path from an object with numeric keys. If the resolved value is undefined, the defaultValue is returned instead.
|
|
350
|
-
*
|
|
351
|
-
* @template T - The type of the value.
|
|
352
|
-
*
|
|
353
|
-
* @param {Record<number, T>} object - The object to query.
|
|
354
|
-
* @param {number} path - The path of the property to get.
|
|
355
|
-
* @returns {T} - Returns the resolved value.
|
|
356
|
-
*/
|
|
357
|
-
declare function get<T>(object: Record<number, T>, path: number): T;
|
|
358
|
-
/**
|
|
359
|
-
* Retrieves the value at a given path from an object with numeric keys. If the resolved value is undefined, the defaultValue is returned instead.
|
|
360
|
-
*
|
|
361
|
-
* @template T - The type of the value.
|
|
362
|
-
*
|
|
363
|
-
* @param {Record<number, T> | null | undefined} object - The object to query.
|
|
364
|
-
* @param {number} path - The path of the property to get.
|
|
365
|
-
* @returns {T | undefined} - Returns the resolved value.
|
|
366
|
-
*/
|
|
367
|
-
declare function get<T>(object: Record<number, T> | null | undefined, path: number): T | undefined;
|
|
368
|
-
/**
|
|
369
|
-
* Retrieves the value at a given path from an object with numeric keys. If the resolved value is undefined, the defaultValue is returned instead.
|
|
370
|
-
*
|
|
371
|
-
* @template T - The type of the value.
|
|
372
|
-
* @template D - The type of the default value.
|
|
373
|
-
*
|
|
374
|
-
* @param {Record<number, T> | null | undefined} object - The object to query.
|
|
375
|
-
* @param {number} path - The path of the property to get.
|
|
376
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
377
|
-
* @returns {T | D} - Returns the resolved value.
|
|
378
|
-
*/
|
|
379
|
-
declare function get<T, D>(object: Record<number, T> | null | undefined, path: number, defaultValue: D): T | D;
|
|
380
|
-
/**
|
|
381
|
-
* Retrieves the value at a given path from a null or undefined object, returning the default value.
|
|
382
|
-
*
|
|
383
|
-
* @template D - The type of the default value.
|
|
384
|
-
*
|
|
385
|
-
* @param {null | undefined} object - The object to query.
|
|
386
|
-
* @param {PropertyKey} path - The path of the property to get.
|
|
387
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
388
|
-
* @returns {D} - Returns the default value.
|
|
389
|
-
*/
|
|
390
|
-
declare function get<D>(object: null | undefined, path: PropertyKey, defaultValue: D): D;
|
|
391
|
-
/**
|
|
392
|
-
* Retrieves the value at a given path from a null or undefined object, returning undefined.
|
|
393
|
-
*
|
|
394
|
-
* @param {null | undefined} object - The object to query.
|
|
395
|
-
* @param {PropertyKey} path - The path of the property to get.
|
|
396
|
-
* @returns {undefined} - Returns undefined.
|
|
397
|
-
*/
|
|
398
|
-
declare function get(object: null | undefined, path: PropertyKey): undefined;
|
|
399
|
-
/**
|
|
400
|
-
* Retrieves the value at a given path from a string-keyed object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
401
|
-
*
|
|
402
|
-
* @template T - The type of the object.
|
|
403
|
-
* @template P - The type of the path.
|
|
404
|
-
*
|
|
405
|
-
* @param {T} data - The object to query.
|
|
406
|
-
* @param {P} path - The path of the property to get.
|
|
407
|
-
* @returns {string extends P ? any : Get<T, P>} - Returns the resolved value.
|
|
408
|
-
*/
|
|
409
|
-
declare function get<T, P extends string>(data: T, path: P): string extends P ? any : Get<T, P>;
|
|
410
|
-
/**
|
|
411
|
-
* Retrieves the value at a given path from a string-keyed object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
412
|
-
*
|
|
413
|
-
* @template T - The type of the object.
|
|
414
|
-
* @template P - The type of the path.
|
|
415
|
-
* @template D - The type of the default value.
|
|
416
|
-
*
|
|
417
|
-
* @param {T} data - The object to query.
|
|
418
|
-
* @param {P} path - The path of the property to get.
|
|
419
|
-
* @param {D} defaultValue - The value returned if the resolved value is undefined.
|
|
420
|
-
* @returns {Exclude<Get<T, P>, null | undefined> | D} - Returns the resolved value.
|
|
421
|
-
*/
|
|
422
|
-
declare function get<T, P extends string, D = Get<T, P>>(data: T, path: P, defaultValue: D): Exclude<Get<T, P>, null | undefined> | D;
|
|
423
|
-
/**
|
|
424
|
-
* Retrieves the value at a given path from an object. If the resolved value is undefined, the defaultValue is returned instead.
|
|
425
|
-
*
|
|
426
|
-
* @param {unknown} object - The object to query.
|
|
427
|
-
* @param {PropertyKey | readonly PropertyKey[]} path - The path of the property to get.
|
|
428
|
-
* @param {unknown} [defaultValue] - The value returned if the resolved value is undefined.
|
|
429
|
-
* @returns {any} - Returns the resolved value.
|
|
430
|
-
*/
|
|
431
|
-
declare function get(object: unknown, path: PropertyKey | readonly PropertyKey[], defaultValue?: unknown): any;
|
|
432
|
-
|
|
433
|
-
/**
|
|
434
|
-
* Sets the value at the specified path of the given object. If any part of the path does not exist, it will be created.
|
|
435
|
-
*
|
|
436
|
-
* @template T - The type of the object.
|
|
437
|
-
* @param {Settable} obj - The object to modify.
|
|
438
|
-
* @param {Path} path - The path of the property to set.
|
|
439
|
-
* @param {any} value - The value to set.
|
|
440
|
-
* @returns {T} - The modified object.
|
|
441
|
-
*
|
|
442
|
-
* @example
|
|
443
|
-
* // Set a value in a nested object
|
|
444
|
-
* const obj = { a: { b: { c: 3 } } };
|
|
445
|
-
* set(obj, 'a.b.c', 4);
|
|
446
|
-
* console.log(obj.a.b.c); // 4
|
|
447
|
-
*
|
|
448
|
-
* @example
|
|
449
|
-
* // Set a value in an array
|
|
450
|
-
* const arr = [1, 2, 3];
|
|
451
|
-
* set(arr, 1, 4);
|
|
452
|
-
* console.log(arr[1]); // 4
|
|
453
|
-
*
|
|
454
|
-
* @example
|
|
455
|
-
* // Create non-existent path and set value
|
|
456
|
-
* const obj = {};
|
|
457
|
-
* set(obj, 'a.b.c', 4);
|
|
458
|
-
* console.log(obj); // { a: { b: { c: 4 } } }
|
|
459
|
-
*/
|
|
460
|
-
declare function set<T>(obj: object, path: PropertyKey | readonly PropertyKey[], value: unknown): T;
|
|
461
|
-
|
|
462
|
-
/**
|
|
463
|
-
* Checks if a given value is a plain object.
|
|
464
|
-
*
|
|
465
|
-
* A plain object is an object created by the `{}` literal, `new Object()`, or
|
|
466
|
-
* `Object.create(null)`.
|
|
467
|
-
*
|
|
468
|
-
* This function also handles objects with custom
|
|
469
|
-
* `Symbol.toStringTag` properties.
|
|
470
|
-
*
|
|
471
|
-
* `Symbol.toStringTag` is a built-in symbol that a constructor can use to customize the
|
|
472
|
-
* default string description of objects.
|
|
473
|
-
*
|
|
474
|
-
* @param {unknown} [object] - The value to check.
|
|
475
|
-
* @returns {boolean} - True if the value is a plain object, otherwise false.
|
|
476
|
-
*
|
|
477
|
-
* @example
|
|
478
|
-
* console.log(isPlainObject({})); // true
|
|
479
|
-
* console.log(isPlainObject([])); // false
|
|
480
|
-
* console.log(isPlainObject(null)); // false
|
|
481
|
-
* console.log(isPlainObject(Object.create(null))); // true
|
|
482
|
-
* console.log(isPlainObject(new Map())); // false
|
|
483
|
-
*/
|
|
484
|
-
declare function isPlainObject(object?: unknown): boolean;
|
|
485
|
-
|
|
486
|
-
/**
|
|
487
|
-
* Checks if a string contains another string at the beginning of the string.
|
|
488
|
-
*
|
|
489
|
-
* Checks if one string startsWith another string. Optional position parameter to start searching from a certain index.
|
|
490
|
-
*
|
|
491
|
-
* @param {string} str - The string that might contain the target string.
|
|
492
|
-
* @param {string} target - The string to search for.
|
|
493
|
-
* @param {number} position - An optional offset to start searching in the str string
|
|
494
|
-
* @returns {boolean} - True if the str string starts with the target string.
|
|
495
|
-
*
|
|
496
|
-
* @example
|
|
497
|
-
* const isPrefix = startsWith('fooBar', 'foo') // returns true
|
|
498
|
-
* const isPrefix = startsWith('fooBar', 'bar') // returns false
|
|
499
|
-
* const isPrefix = startsWith('fooBar', 'abc') // returns false
|
|
500
|
-
* const isPrefix = startsWith('fooBar', 'Bar', 2) // returns true
|
|
501
|
-
* const isPrefix = startsWith('fooBar', 'Bar', 5) // returns false
|
|
502
|
-
*/
|
|
503
|
-
declare const startsWith: (str: string, target: string, position?: number) => boolean;
|
|
504
|
-
|
|
505
|
-
/**
|
|
506
|
-
* Checks if a string contains another string at the end of the string.
|
|
507
|
-
*
|
|
508
|
-
* Checks if one string endsWith another string. Optional position parameter to offset searching before a certain index.
|
|
509
|
-
*
|
|
510
|
-
* @param {string} str - The string that might contain the target string.
|
|
511
|
-
* @param {string} target - The string to search for.
|
|
512
|
-
* @param {number} position - An optional position from the start to search up to this index
|
|
513
|
-
* @returns {boolean} - True if the str string ends with the target string.
|
|
514
|
-
*
|
|
515
|
-
* @example
|
|
516
|
-
* const isPrefix = endsWith('fooBar', 'foo') // returns true
|
|
517
|
-
* const isPrefix = endsWith('fooBar', 'bar') // returns false
|
|
518
|
-
* const isPrefix = endsWith('fooBar', 'abc') // returns false
|
|
519
|
-
* const isPrefix = endsWith('fooBar', 'foo', 3) // returns true
|
|
520
|
-
* const isPrefix = endsWith('fooBar', 'abc', 5) // returns false
|
|
521
|
-
*/
|
|
522
|
-
declare const endsWith: (str: string, target: string, position?: number) => boolean;
|
|
523
|
-
|
|
524
|
-
/**
|
|
525
|
-
* Finds the element in an array that has the maximum value.
|
|
526
|
-
*
|
|
527
|
-
* @template T - The type of elements in the array.
|
|
528
|
-
* @param {T[]} items The array of elements to search.
|
|
529
|
-
* @returns {T} The element with the maximum value.
|
|
530
|
-
* @example
|
|
531
|
-
* // Returns 9
|
|
532
|
-
* max([3, 1, 4, 1, 5, 9])
|
|
533
|
-
*
|
|
534
|
-
* @example
|
|
535
|
-
* // Returns 8
|
|
536
|
-
* max([0, -3, 2, 8, 7])
|
|
537
|
-
*/
|
|
538
|
-
declare function max<T>(items?: readonly T[]): T;
|
|
539
|
-
|
|
540
|
-
/**
|
|
541
|
-
* Finds the element in an array that has the minimum value.
|
|
542
|
-
*
|
|
543
|
-
* @template T - The type of elements in the array.
|
|
544
|
-
* @param {T[]} items The array of elements to search.
|
|
545
|
-
* @returns {T} The element with the minimum value.
|
|
546
|
-
* @example
|
|
547
|
-
* // Returns 1
|
|
548
|
-
* min([3, 1, 4, 1, 5, 9])
|
|
549
|
-
*
|
|
550
|
-
* @example
|
|
551
|
-
* // Returns -3
|
|
552
|
-
* min([0, -3, 2, 8, 7])
|
|
553
|
-
*/
|
|
554
|
-
declare function min<T>(items?: readonly T[]): T;
|
|
555
|
-
|
|
556
|
-
export { chunk, concat, difference, endsWith, get, isPlainObject, max, min, set, startsWith, zipObjectDeep };
|
|
92
|
+
export { chunk } from './array/chunk.js';
|
|
93
|
+
export { concat } from './array/concat.js';
|
|
94
|
+
export { difference } from './array/difference.js';
|
|
95
|
+
export { fill } from './array/fill.js';
|
|
96
|
+
export { flatten } from './array/flatten.js';
|
|
97
|
+
export { flattenDeep } from './array/flattenDeep.js';
|
|
98
|
+
export { flattenDepth } from './array/flattenDepth.js';
|
|
99
|
+
export { size } from './array/size.js';
|
|
100
|
+
export { zipObjectDeep } from './array/zipObjectDeep.js';
|
|
101
|
+
export { ary } from './function/ary.js';
|
|
102
|
+
export { bind } from './function/bind.js';
|
|
103
|
+
export { get } from './object/get.js';
|
|
104
|
+
export { set } from './object/set.js';
|
|
105
|
+
export { property } from './object/property.js';
|
|
106
|
+
export { mapKeys } from './object/mapKeys.js';
|
|
107
|
+
export { mapValues } from './object/mapValues.js';
|
|
108
|
+
export { isPlainObject } from './predicate/isPlainObject.js';
|
|
109
|
+
export { isArray } from './predicate/isArray.js';
|
|
110
|
+
export { isArguments } from './predicate/isArguments.js';
|
|
111
|
+
export { isArrayLike } from './predicate/isArrayLike.js';
|
|
112
|
+
export { isObjectLike } from './predicate/isObjectLike.js';
|
|
113
|
+
export { isBoolean } from './predicate/isBoolean.js';
|
|
114
|
+
export { isTypedArray } from './predicate/isTypedArray.js';
|
|
115
|
+
export { isMatch } from './predicate/isMatch.js';
|
|
116
|
+
export { matches } from './predicate/matches.js';
|
|
117
|
+
export { startsWith } from './string/startsWith.js';
|
|
118
|
+
export { endsWith } from './string/endsWith.js';
|
|
119
|
+
export { padStart } from './string/padStart.js';
|
|
120
|
+
export { max } from './math/max.js';
|
|
121
|
+
export { min } from './math/min.js';
|