es-toolkit 1.38.0-dev.1300 → 1.38.0-dev.1302
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/.yarn/sdks/eslint/bin/eslint.js +32 -0
- package/.yarn/sdks/eslint/lib/api.js +32 -0
- package/.yarn/sdks/eslint/lib/config-api.js +32 -0
- package/.yarn/sdks/eslint/lib/universal.js +32 -0
- package/.yarn/sdks/eslint/lib/unsupported-api.js +32 -0
- package/.yarn/sdks/typescript/lib/tsc.js +32 -0
- package/.yarn/sdks/typescript/lib/tsserver.js +248 -0
- package/.yarn/sdks/typescript/lib/tsserverlibrary.js +248 -0
- package/.yarn/sdks/typescript/lib/typescript.js +32 -0
- package/array.js +1 -0
- package/compat/DebouncedFunc.js +1 -0
- package/compat/DebouncedFunction.js +1 -0
- package/compat/add.js +1 -0
- package/compat/after.js +1 -0
- package/compat/ary.js +1 -0
- package/compat/assign.js +1 -0
- package/compat/assignIn.js +1 -0
- package/compat/assignInWith.js +1 -0
- package/compat/assignWith.js +1 -0
- package/compat/at.js +1 -0
- package/compat/attempt.js +1 -0
- package/compat/before.js +1 -0
- package/compat/bind.js +1 -0
- package/compat/bindAll.js +1 -0
- package/compat/bindKey.js +1 -0
- package/compat/camelCase.js +1 -0
- package/compat/capitalize.js +1 -0
- package/compat/castArray.js +1 -0
- package/compat/ceil.js +1 -0
- package/compat/chunk.js +1 -0
- package/compat/clamp.js +1 -0
- package/compat/clone.js +1 -0
- package/compat/cloneDeep.js +1 -0
- package/compat/cloneDeepWith.js +1 -0
- package/compat/cloneWith.js +1 -0
- package/compat/compact.js +1 -0
- package/compat/concat.js +1 -0
- package/compat/cond.js +1 -0
- package/compat/conforms.js +1 -0
- package/compat/conformsTo.js +1 -0
- package/compat/constant.js +1 -0
- package/compat/countBy.js +1 -0
- package/compat/create.js +1 -0
- package/compat/curry.js +1 -0
- package/compat/curryRight.js +1 -0
- package/compat/debounce.js +1 -0
- package/compat/deburr.js +1 -0
- package/compat/defaultTo.js +1 -0
- package/compat/defaults.js +1 -0
- package/compat/defaultsDeep.js +1 -0
- package/compat/defer.js +1 -0
- package/compat/delay.js +1 -0
- package/compat/difference.js +1 -0
- package/compat/differenceBy.js +1 -0
- package/compat/differenceWith.js +1 -0
- package/compat/divide.js +1 -0
- package/compat/drop.js +1 -0
- package/compat/dropRight.js +1 -0
- package/compat/dropRightWhile.js +1 -0
- package/compat/dropWhile.js +1 -0
- package/compat/each.js +1 -0
- package/compat/eachRight.js +1 -0
- package/compat/endsWith.js +1 -0
- package/compat/eq.js +1 -0
- package/compat/escape.js +1 -0
- package/compat/escapeRegExp.js +1 -0
- package/compat/every.js +1 -0
- package/compat/extend.js +1 -0
- package/compat/extendWith.js +1 -0
- package/compat/fill.js +1 -0
- package/compat/filter.js +1 -0
- package/compat/find.js +1 -0
- package/compat/findIndex.js +1 -0
- package/compat/findKey.js +1 -0
- package/compat/findLast.js +1 -0
- package/compat/findLastIndex.js +1 -0
- package/compat/findLastKey.js +1 -0
- package/compat/first.js +1 -0
- package/compat/flatMap.js +1 -0
- package/compat/flatMapDeep.js +1 -0
- package/compat/flatMapDepth.js +1 -0
- package/compat/flatten.js +1 -0
- package/compat/flattenDeep.js +1 -0
- package/compat/flattenDepth.js +1 -0
- package/compat/flip.js +1 -0
- package/compat/floor.js +1 -0
- package/compat/flow.js +1 -0
- package/compat/flowRight.js +1 -0
- package/compat/forEach.js +1 -0
- package/compat/forEachRight.js +1 -0
- package/compat/forIn.js +1 -0
- package/compat/forInRight.js +1 -0
- package/compat/forOwn.js +1 -0
- package/compat/forOwnRight.js +1 -0
- package/compat/fromPairs.js +1 -0
- package/compat/functions.js +1 -0
- package/compat/functionsIn.js +1 -0
- package/compat/get.js +1 -0
- package/compat/groupBy.js +1 -0
- package/compat/gt.js +1 -0
- package/compat/gte.js +1 -0
- package/compat/has.js +1 -0
- package/compat/hasIn.js +1 -0
- package/compat/head.js +1 -0
- package/compat/identity.js +1 -0
- package/compat/inRange.js +1 -0
- package/compat/includes.js +1 -0
- package/compat/indexOf.js +1 -0
- package/compat/initial.js +1 -0
- package/compat/intersection.js +1 -0
- package/compat/intersectionBy.js +1 -0
- package/compat/intersectionWith.js +1 -0
- package/compat/invert.js +1 -0
- package/compat/invertBy.js +1 -0
- package/compat/invoke.js +1 -0
- package/compat/invokeMap.js +1 -0
- package/compat/isArguments.js +1 -0
- package/compat/isArray.js +1 -0
- package/compat/isArrayBuffer.js +1 -0
- package/compat/isArrayLike.js +1 -0
- package/compat/isArrayLikeObject.js +1 -0
- package/compat/isBoolean.js +1 -0
- package/compat/isBuffer.js +1 -0
- package/compat/isDate.js +1 -0
- package/compat/isElement.js +1 -0
- package/compat/isEmpty.js +1 -0
- package/compat/isEqual.js +1 -0
- package/compat/isEqualWith.js +1 -0
- package/compat/isError.js +1 -0
- package/compat/isFinite.js +1 -0
- package/compat/isFunction.js +1 -0
- package/compat/isInteger.js +1 -0
- package/compat/isLength.js +1 -0
- package/compat/isMap.js +1 -0
- package/compat/isMatch.js +1 -0
- package/compat/isMatchWith.js +1 -0
- package/compat/isNaN.js +1 -0
- package/compat/isNative.js +1 -0
- package/compat/isNil.js +1 -0
- package/compat/isNull.js +1 -0
- package/compat/isNumber.js +1 -0
- package/compat/isObject.js +1 -0
- package/compat/isObjectLike.js +1 -0
- package/compat/isPlainObject.js +1 -0
- package/compat/isRegExp.js +1 -0
- package/compat/isSafeInteger.js +1 -0
- package/compat/isSet.js +1 -0
- package/compat/isString.js +1 -0
- package/compat/isSymbol.js +1 -0
- package/compat/isTypedArray.js +1 -0
- package/compat/isUndefined.js +1 -0
- package/compat/isWeakMap.js +1 -0
- package/compat/isWeakSet.js +1 -0
- package/compat/iteratee.js +1 -0
- package/compat/join.js +1 -0
- package/compat/kebabCase.js +1 -0
- package/compat/keyBy.js +1 -0
- package/compat/keys.js +1 -0
- package/compat/keysIn.js +1 -0
- package/compat/last.js +1 -0
- package/compat/lastIndexOf.js +1 -0
- package/compat/lowerCase.js +1 -0
- package/compat/lowerFirst.js +1 -0
- package/compat/lt.js +1 -0
- package/compat/lte.js +1 -0
- package/compat/map.js +1 -0
- package/compat/mapKeys.js +1 -0
- package/compat/mapValues.js +1 -0
- package/compat/matches.js +1 -0
- package/compat/matchesProperty.js +1 -0
- package/compat/max.js +1 -0
- package/compat/maxBy.js +1 -0
- package/compat/mean.js +1 -0
- package/compat/meanBy.js +1 -0
- package/compat/memoize.js +1 -0
- package/compat/merge.js +1 -0
- package/compat/mergeWith.js +1 -0
- package/compat/method.js +1 -0
- package/compat/methodOf.js +1 -0
- package/compat/min.js +1 -0
- package/compat/minBy.js +1 -0
- package/compat/multiply.js +1 -0
- package/compat/negate.js +1 -0
- package/compat/noop.js +1 -0
- package/compat/now.js +1 -0
- package/compat/nth.js +1 -0
- package/compat/nthArg.js +1 -0
- package/compat/omit.js +1 -0
- package/compat/omitBy.js +1 -0
- package/compat/once.js +1 -0
- package/compat/orderBy.js +1 -0
- package/compat/over.js +1 -0
- package/compat/overArgs.js +1 -0
- package/compat/overEvery.js +1 -0
- package/compat/overSome.js +1 -0
- package/compat/pad.js +1 -0
- package/compat/padEnd.js +1 -0
- package/compat/padStart.js +1 -0
- package/compat/parseInt.js +1 -0
- package/compat/partial.js +1 -0
- package/compat/partialRight.js +1 -0
- package/compat/partition.js +1 -0
- package/compat/pick.js +1 -0
- package/compat/pickBy.js +1 -0
- package/compat/property.js +1 -0
- package/compat/propertyOf.js +1 -0
- package/compat/pull.js +1 -0
- package/compat/pullAll.js +1 -0
- package/compat/pullAllBy.js +1 -0
- package/compat/pullAllWith.js +1 -0
- package/compat/pullAt.js +1 -0
- package/compat/random.js +1 -0
- package/compat/range.js +1 -0
- package/compat/rangeRight.js +1 -0
- package/compat/rearg.js +1 -0
- package/compat/reduce.js +1 -0
- package/compat/reduceRight.js +1 -0
- package/compat/reject.js +1 -0
- package/compat/remove.js +1 -0
- package/compat/repeat.js +1 -0
- package/compat/replace.js +1 -0
- package/compat/rest.js +1 -0
- package/compat/result.js +1 -0
- package/compat/reverse.js +1 -0
- package/compat/round.js +1 -0
- package/compat/sample.js +1 -0
- package/compat/sampleSize.js +1 -0
- package/compat/set.js +1 -0
- package/compat/setWith.js +1 -0
- package/compat/shuffle.js +1 -0
- package/compat/size.js +1 -0
- package/compat/slice.js +1 -0
- package/compat/snakeCase.js +1 -0
- package/compat/some.js +1 -0
- package/compat/sortBy.js +1 -0
- package/compat/sortedIndex.js +1 -0
- package/compat/sortedIndexBy.js +1 -0
- package/compat/sortedIndexOf.js +1 -0
- package/compat/sortedLastIndex.js +1 -0
- package/compat/sortedLastIndexBy.js +1 -0
- package/compat/sortedLastIndexOf.js +1 -0
- package/compat/split.js +1 -0
- package/compat/spread.js +1 -0
- package/compat/startCase.js +1 -0
- package/compat/startsWith.js +1 -0
- package/compat/stubArray.js +1 -0
- package/compat/stubFalse.js +1 -0
- package/compat/stubObject.js +1 -0
- package/compat/stubString.js +1 -0
- package/compat/stubTrue.js +1 -0
- package/compat/subtract.js +1 -0
- package/compat/sum.js +1 -0
- package/compat/sumBy.js +1 -0
- package/compat/tail.js +1 -0
- package/compat/take.js +1 -0
- package/compat/takeRight.js +1 -0
- package/compat/takeRightWhile.js +1 -0
- package/compat/takeWhile.js +1 -0
- package/compat/template.js +1 -0
- package/compat/templateSettings.js +1 -0
- package/compat/throttle.js +1 -0
- package/compat/times.js +1 -0
- package/compat/toArray.js +1 -0
- package/compat/toDefaulted.js +1 -0
- package/compat/toFinite.js +1 -0
- package/compat/toInteger.js +1 -0
- package/compat/toLength.js +1 -0
- package/compat/toLower.js +1 -0
- package/compat/toNumber.js +1 -0
- package/compat/toPairs.js +1 -0
- package/compat/toPairsIn.js +1 -0
- package/compat/toPath.js +1 -0
- package/compat/toPlainObject.js +1 -0
- package/compat/toSafeInteger.js +1 -0
- package/compat/toString.js +1 -0
- package/compat/toUpper.js +1 -0
- package/compat/transform.js +1 -0
- package/compat/trim.js +1 -0
- package/compat/trimEnd.js +1 -0
- package/compat/trimStart.js +1 -0
- package/compat/truncate.js +1 -0
- package/compat/unary.js +1 -0
- package/compat/unescape.js +1 -0
- package/compat/union.js +1 -0
- package/compat/unionBy.js +1 -0
- package/compat/unionWith.js +1 -0
- package/compat/uniq.js +1 -0
- package/compat/uniqBy.js +1 -0
- package/compat/uniqWith.js +1 -0
- package/compat/uniqueId.js +1 -0
- package/compat/unset.js +1 -0
- package/compat/unzip.js +1 -0
- package/compat/unzipWith.js +1 -0
- package/compat/update.js +1 -0
- package/compat/updateWith.js +1 -0
- package/compat/upperCase.js +1 -0
- package/compat/upperFirst.js +1 -0
- package/compat/values.js +1 -0
- package/compat/valuesIn.js +1 -0
- package/compat/without.js +1 -0
- package/compat/words.js +1 -0
- package/compat/wrap.js +1 -0
- package/compat/xor.js +1 -0
- package/compat/xorBy.js +1 -0
- package/compat/xorWith.js +1 -0
- package/compat/zip.js +1 -0
- package/compat/zipObject.js +1 -0
- package/compat/zipObjectDeep.js +1 -0
- package/compat/zipWith.js +1 -0
- package/compat.js +1 -0
- package/dist/_internal/compareValues.js +15 -0
- package/dist/array/at.js +19 -0
- package/dist/array/chunk.js +19 -0
- package/dist/array/compact.js +16 -0
- package/dist/array/countBy.js +15 -0
- package/dist/array/difference.js +10 -0
- package/dist/array/differenceBy.js +12 -0
- package/dist/array/differenceWith.js +13 -0
- package/dist/array/drop.js +10 -0
- package/dist/array/dropRight.js +13 -0
- package/dist/array/dropRightWhile.js +14 -0
- package/dist/array/dropWhile.js +13 -0
- package/dist/array/fill.js +15 -0
- package/dist/array/flatMap.js +11 -0
- package/dist/array/flatMapDeep.js +11 -0
- package/dist/array/flatten.js +23 -0
- package/dist/array/flattenDeep.js +11 -0
- package/dist/array/forEachRight.js +12 -0
- package/dist/array/groupBy.js +18 -0
- package/dist/array/head.js +9 -0
- package/dist/array/index.js +122 -271
- package/dist/array/initial.js +9 -0
- package/dist/array/intersection.js +12 -0
- package/dist/array/intersectionBy.js +10 -0
- package/dist/array/intersectionWith.js +13 -0
- package/dist/array/isSubset.js +11 -0
- package/dist/array/isSubsetWith.js +11 -0
- package/dist/array/keyBy.js +15 -0
- package/dist/array/last.js +9 -0
- package/dist/array/maxBy.js +22 -0
- package/dist/array/minBy.js +22 -0
- package/dist/array/orderBy.js +25 -0
- package/dist/array/partition.js +20 -0
- package/dist/array/pull.js +22 -0
- package/dist/array/pullAt.js +16 -0
- package/dist/array/remove.js +24 -0
- package/dist/array/sample.js +10 -0
- package/dist/array/sampleSize.js +24 -0
- package/dist/array/shuffle.js +14 -0
- package/dist/array/sortBy.js +11 -0
- package/dist/array/tail.js +9 -0
- package/dist/array/take.js +12 -0
- package/dist/array/takeRight.js +15 -0
- package/dist/array/takeRightWhile.js +14 -0
- package/dist/array/takeWhile.js +17 -0
- package/dist/array/toFilled.js +16 -0
- package/dist/array/union.js +11 -0
- package/dist/array/unionBy.js +11 -0
- package/dist/array/unionWith.js +11 -0
- package/dist/array/uniq.js +9 -0
- package/dist/array/uniqBy.js +17 -0
- package/dist/array/uniqWith.js +17 -0
- package/dist/array/unzip.js +22 -0
- package/dist/array/unzipWith.js +18 -0
- package/dist/array/windowed.js +20 -0
- package/dist/array/without.js +11 -0
- package/dist/array/xor.js +13 -0
- package/dist/array/xorBy.js +15 -0
- package/dist/array/xorWith.js +15 -0
- package/dist/array/zip.js +24 -0
- package/dist/array/zipObject.js +13 -0
- package/dist/array/zipWith.js +17 -0
- package/dist/browser.global.js +1 -1
- package/dist/browser.global.js.map +1 -1
- package/dist/compat/DebouncedFunc.js +1 -0
- package/dist/compat/DebouncedFunction.js +1 -0
- package/dist/compat/_internal/MAX_ARRAY_LENGTH.js +7 -0
- package/dist/compat/_internal/MAX_SAFE_INTEGER.js +7 -0
- package/dist/compat/_internal/assignValue.js +14 -0
- package/dist/compat/_internal/compareValues.js +37 -0
- package/dist/compat/_internal/copyArray.js +14 -0
- package/dist/compat/_internal/decimalAdjust.js +23 -0
- package/dist/compat/_internal/flattenArrayLike.js +21 -0
- package/dist/compat/_internal/getSymbols.js +9 -0
- package/dist/compat/_internal/getSymbolsIn.js +16 -0
- package/dist/compat/_internal/getTag.js +12 -0
- package/dist/compat/_internal/isDeepKey.js +17 -0
- package/dist/compat/_internal/isIndex.js +20 -0
- package/dist/compat/_internal/isIterateeCall.js +21 -0
- package/dist/compat/_internal/isKey.js +20 -0
- package/dist/compat/_internal/isPrototype.js +11 -0
- package/dist/compat/_internal/mapToEntries.js +15 -0
- package/dist/compat/_internal/normalizeForCase.js +14 -0
- package/dist/compat/_internal/setToEntries.js +15 -0
- package/dist/{_chunk/isPlainObject-Xaozpc.js → compat/_internal/tags.js} +1 -37
- package/dist/compat/_internal/toArray.js +9 -0
- package/dist/compat/_internal/toKey.js +15 -0
- package/dist/compat/add.js +1 -0
- package/dist/compat/after.js +1 -0
- package/dist/compat/array/castArray.js +12 -0
- package/dist/compat/array/chunk.js +17 -0
- package/dist/compat/array/compact.js +15 -0
- package/dist/compat/array/concat.js +11 -0
- package/dist/compat/array/countBy.d.mts +22 -0
- package/dist/compat/array/countBy.d.ts +22 -0
- package/dist/compat/array/countBy.js +23 -0
- package/dist/compat/array/countBy.mjs +19 -0
- package/dist/compat/array/difference.js +24 -0
- package/dist/compat/array/differenceBy.js +24 -0
- package/dist/compat/array/differenceWith.js +23 -0
- package/dist/compat/array/drop.js +18 -0
- package/dist/compat/array/dropRight.js +18 -0
- package/dist/compat/array/dropRightWhile.js +40 -0
- package/dist/compat/array/dropWhile.js +41 -0
- package/dist/compat/array/every.js +64 -0
- package/dist/compat/array/fill.js +27 -0
- package/dist/compat/array/filter.js +37 -0
- package/dist/compat/array/find.js +30 -0
- package/dist/compat/array/findIndex.js +43 -0
- package/dist/compat/array/findLast.js +36 -0
- package/dist/compat/array/findLastIndex.js +43 -0
- package/dist/compat/array/flatMap.js +17 -0
- package/dist/compat/array/flatMapDeep.js +11 -0
- package/dist/compat/array/flatMapDepth.js +18 -0
- package/dist/compat/array/flatten.js +36 -0
- package/dist/compat/array/flattenDeep.js +11 -0
- package/dist/compat/array/flattenDepth.js +11 -0
- package/dist/compat/array/forEach.js +25 -0
- package/dist/compat/array/forEachRight.js +25 -0
- package/dist/compat/array/groupBy.js +19 -0
- package/dist/compat/array/head.js +16 -0
- package/dist/compat/array/includes.js +44 -0
- package/dist/compat/array/indexOf.js +26 -0
- package/dist/compat/array/initial.js +15 -0
- package/dist/compat/array/intersection.js +27 -0
- package/dist/compat/array/intersectionBy.js +40 -0
- package/dist/compat/array/intersectionWith.js +46 -0
- package/dist/compat/array/invokeMap.js +40 -0
- package/dist/compat/array/join.js +14 -0
- package/dist/compat/array/keyBy.js +23 -0
- package/dist/compat/array/last.js +16 -0
- package/dist/compat/array/lastIndexOf.js +26 -0
- package/dist/compat/array/map.js +25 -0
- package/dist/compat/array/nth.js +19 -0
- package/dist/compat/array/orderBy.js +82 -0
- package/dist/compat/array/partition.js +28 -0
- package/dist/compat/array/pull.js +11 -0
- package/dist/compat/array/pullAll.js +11 -0
- package/dist/compat/array/pullAllBy.js +26 -0
- package/dist/compat/array/pullAllWith.js +37 -0
- package/dist/compat/array/pullAt.js +38 -0
- package/dist/compat/array/reduce.js +37 -0
- package/dist/compat/array/reduceRight.js +43 -0
- package/dist/compat/array/reject.js +13 -0
- package/dist/compat/array/remove.js +12 -0
- package/dist/compat/array/reverse.js +12 -0
- package/dist/compat/array/sample.js +19 -0
- package/dist/compat/array/sampleSize.js +22 -0
- package/dist/compat/array/shuffle.js +28 -0
- package/dist/compat/array/size.js +17 -0
- package/dist/compat/array/slice.js +43 -0
- package/dist/compat/array/some.js +86 -0
- package/dist/compat/array/sortBy.js +20 -0
- package/dist/compat/array/sortedIndex.js +34 -0
- package/dist/compat/array/sortedIndexBy.js +62 -0
- package/dist/compat/array/sortedIndexOf.js +19 -0
- package/dist/compat/array/sortedLastIndex.js +35 -0
- package/dist/compat/array/sortedLastIndexBy.js +11 -0
- package/dist/compat/array/sortedLastIndexOf.js +19 -0
- package/dist/compat/array/tail.js +16 -0
- package/dist/compat/array/take.js +18 -0
- package/dist/compat/array/takeRight.js +18 -0
- package/dist/compat/array/takeRightWhile.js +19 -0
- package/dist/compat/array/takeWhile.js +19 -0
- package/dist/compat/array/union.js +15 -0
- package/dist/compat/array/unionBy.js +21 -0
- package/dist/compat/array/unionWith.js +20 -0
- package/dist/compat/array/uniq.js +15 -0
- package/dist/compat/array/uniqBy.js +16 -0
- package/dist/compat/array/uniqWith.js +16 -0
- package/dist/compat/array/unzip.js +18 -0
- package/dist/compat/array/unzipWith.js +25 -0
- package/dist/compat/array/without.js +15 -0
- package/dist/compat/array/xor.js +34 -0
- package/dist/compat/array/xorBy.js +27 -0
- package/dist/compat/array/xorWith.js +25 -0
- package/dist/compat/array/zip.js +15 -0
- package/dist/compat/array/zipObject.js +15 -0
- package/dist/compat/array/zipObjectDeep.js +27 -0
- package/dist/compat/array/zipWith.js +24 -0
- package/dist/compat/ary.js +1 -0
- package/dist/compat/assign.js +1 -0
- package/dist/compat/assignIn.js +1 -0
- package/dist/compat/assignInWith.js +1 -0
- package/dist/compat/assignWith.js +1 -0
- package/dist/compat/at.js +1 -0
- package/dist/compat/attempt.js +1 -0
- package/dist/compat/before.js +1 -0
- package/dist/compat/bind.js +1 -0
- package/dist/compat/bindAll.js +1 -0
- package/dist/compat/bindKey.js +1 -0
- package/dist/compat/camelCase.js +1 -0
- package/dist/compat/capitalize.js +1 -0
- package/dist/compat/castArray.js +1 -0
- package/dist/compat/ceil.js +1 -0
- package/dist/compat/chunk.js +1 -0
- package/dist/compat/clamp.js +1 -0
- package/dist/compat/clone.js +1 -0
- package/dist/compat/cloneDeep.js +1 -0
- package/dist/compat/cloneDeepWith.js +1 -0
- package/dist/compat/cloneWith.js +1 -0
- package/dist/compat/compact.js +1 -0
- package/dist/compat/compat.d.mts +17 -16
- package/dist/compat/compat.d.ts +17 -16
- package/dist/compat/compat.js +595 -0
- package/dist/compat/compat.mjs +17 -16
- package/dist/compat/concat.js +1 -0
- package/dist/compat/cond.js +1 -0
- package/dist/compat/conforms.js +1 -0
- package/dist/compat/conformsTo.js +1 -0
- package/dist/compat/constant.js +1 -0
- package/dist/compat/countBy.js +1 -0
- package/dist/compat/create.js +1 -0
- package/dist/compat/curry.js +1 -0
- package/dist/compat/curryRight.js +1 -0
- package/dist/compat/debounce.js +1 -0
- package/dist/compat/deburr.js +1 -0
- package/dist/compat/defaultTo.js +1 -0
- package/dist/compat/defaults.js +1 -0
- package/dist/compat/defaultsDeep.js +1 -0
- package/dist/compat/defer.js +1 -0
- package/dist/compat/delay.js +1 -0
- package/dist/compat/difference.js +1 -0
- package/dist/compat/differenceBy.js +1 -0
- package/dist/compat/differenceWith.js +1 -0
- package/dist/compat/divide.js +1 -0
- package/dist/compat/drop.js +1 -0
- package/dist/compat/dropRight.js +1 -0
- package/dist/compat/dropRightWhile.js +1 -0
- package/dist/compat/dropWhile.js +1 -0
- package/dist/compat/each.js +1 -0
- package/dist/compat/eachRight.js +1 -0
- package/dist/compat/endsWith.js +1 -0
- package/dist/compat/eq.js +1 -0
- package/dist/compat/escape.js +1 -0
- package/dist/compat/escapeRegExp.js +1 -0
- package/dist/compat/every.js +1 -0
- package/dist/compat/extend.js +1 -0
- package/dist/compat/extendWith.js +1 -0
- package/dist/compat/fill.js +1 -0
- package/dist/compat/filter.js +1 -0
- package/dist/compat/find.js +1 -0
- package/dist/compat/findIndex.js +1 -0
- package/dist/compat/findKey.js +1 -0
- package/dist/compat/findLast.js +1 -0
- package/dist/compat/findLastIndex.js +1 -0
- package/dist/compat/findLastKey.js +1 -0
- package/dist/compat/first.js +1 -0
- package/dist/compat/flatMap.js +1 -0
- package/dist/compat/flatMapDeep.js +1 -0
- package/dist/compat/flatMapDepth.js +1 -0
- package/dist/compat/flatten.js +1 -0
- package/dist/compat/flattenDeep.js +1 -0
- package/dist/compat/flattenDepth.js +1 -0
- package/dist/compat/flip.js +1 -0
- package/dist/compat/floor.js +1 -0
- package/dist/compat/flow.js +1 -0
- package/dist/compat/flowRight.js +1 -0
- package/dist/compat/forEach.js +1 -0
- package/dist/compat/forEachRight.js +1 -0
- package/dist/compat/forIn.js +1 -0
- package/dist/compat/forInRight.js +1 -0
- package/dist/compat/forOwn.js +1 -0
- package/dist/compat/forOwnRight.js +1 -0
- package/dist/compat/fromPairs.js +1 -0
- package/dist/compat/function/after.js +19 -0
- package/dist/compat/function/ary.js +17 -0
- package/dist/compat/function/attempt.js +14 -0
- package/dist/compat/function/before.js +24 -0
- package/dist/compat/function/bind.js +31 -0
- package/dist/compat/function/bindKey.js +31 -0
- package/dist/compat/function/curry.js +61 -0
- package/dist/compat/function/curryRight.js +68 -0
- package/dist/compat/function/debounce.js +50 -0
- package/dist/compat/function/defer.js +12 -0
- package/dist/compat/function/delay.js +14 -0
- package/dist/compat/function/flip.js +11 -0
- package/dist/compat/function/flow.js +16 -0
- package/dist/compat/function/flowRight.js +16 -0
- package/dist/compat/function/memoize.js +25 -0
- package/dist/compat/function/negate.js +14 -0
- package/dist/compat/function/nthArg.js +13 -0
- package/dist/compat/function/overArgs.js +24 -0
- package/dist/compat/function/partial.js +12 -0
- package/dist/compat/function/partialRight.js +12 -0
- package/dist/compat/function/rearg.js +18 -0
- package/dist/compat/function/rest.js +15 -0
- package/dist/compat/function/spread.js +20 -0
- package/dist/compat/function/throttle.js +20 -0
- package/dist/compat/function/wrap.js +15 -0
- package/dist/compat/functions.js +1 -0
- package/dist/compat/functionsIn.js +1 -0
- package/dist/compat/get.js +1 -0
- package/dist/compat/groupBy.js +1 -0
- package/dist/compat/gt.js +1 -0
- package/dist/compat/gte.js +1 -0
- package/dist/compat/has.js +1 -0
- package/dist/compat/hasIn.js +1 -0
- package/dist/compat/head.js +1 -0
- package/dist/compat/identity.js +1 -0
- package/dist/compat/inRange.js +1 -0
- package/dist/compat/includes.js +1 -0
- package/dist/compat/index.d.mts +17 -16
- package/dist/compat/index.d.ts +17 -16
- package/dist/compat/index.js +591 -5242
- package/dist/compat/index.mjs +17 -16
- package/dist/compat/indexOf.js +1 -0
- package/dist/compat/initial.js +1 -0
- package/dist/compat/intersection.js +1 -0
- package/dist/compat/intersectionBy.js +1 -0
- package/dist/compat/intersectionWith.js +1 -0
- package/dist/compat/invert.js +1 -0
- package/dist/compat/invertBy.js +1 -0
- package/dist/compat/invoke.js +1 -0
- package/dist/compat/invokeMap.js +1 -0
- package/dist/compat/isArguments.js +1 -0
- package/dist/compat/isArray.js +1 -0
- package/dist/compat/isArrayBuffer.js +1 -0
- package/dist/compat/isArrayLike.js +1 -0
- package/dist/compat/isArrayLikeObject.js +1 -0
- package/dist/compat/isBoolean.js +1 -0
- package/dist/compat/isBuffer.js +1 -0
- package/dist/compat/isDate.js +1 -0
- package/dist/compat/isElement.js +1 -0
- package/dist/compat/isEmpty.js +1 -0
- package/dist/compat/isEqual.js +1 -0
- package/dist/compat/isEqualWith.js +1 -0
- package/dist/compat/isError.js +1 -0
- package/dist/compat/isFinite.js +1 -0
- package/dist/compat/isFunction.js +1 -0
- package/dist/compat/isInteger.js +1 -0
- package/dist/compat/isLength.js +1 -0
- package/dist/compat/isMap.js +1 -0
- package/dist/compat/isMatch.js +1 -0
- package/dist/compat/isMatchWith.js +1 -0
- package/dist/compat/isNaN.js +1 -0
- package/dist/compat/isNative.js +1 -0
- package/dist/compat/isNil.js +1 -0
- package/dist/compat/isNull.js +1 -0
- package/dist/compat/isNumber.js +1 -0
- package/dist/compat/isObject.js +1 -0
- package/dist/compat/isObjectLike.js +1 -0
- package/dist/compat/isPlainObject.js +1 -0
- package/dist/compat/isRegExp.js +1 -0
- package/dist/compat/isSafeInteger.js +1 -0
- package/dist/compat/isSet.js +1 -0
- package/dist/compat/isString.js +1 -0
- package/dist/compat/isSymbol.js +1 -0
- package/dist/compat/isTypedArray.js +1 -0
- package/dist/compat/isUndefined.js +1 -0
- package/dist/compat/isWeakMap.js +1 -0
- package/dist/compat/isWeakSet.js +1 -0
- package/dist/compat/iteratee.js +1 -0
- package/dist/compat/join.js +1 -0
- package/dist/compat/kebabCase.js +1 -0
- package/dist/compat/keyBy.js +1 -0
- package/dist/compat/keys.js +1 -0
- package/dist/compat/keysIn.js +1 -0
- package/dist/compat/last.js +1 -0
- package/dist/compat/lastIndexOf.js +1 -0
- package/dist/compat/lowerCase.js +1 -0
- package/dist/compat/lowerFirst.js +1 -0
- package/dist/compat/lt.js +1 -0
- package/dist/compat/lte.js +1 -0
- package/dist/compat/map.js +1 -0
- package/dist/compat/mapKeys.js +1 -0
- package/dist/compat/mapValues.js +1 -0
- package/dist/compat/matches.js +1 -0
- package/dist/compat/matchesProperty.js +1 -0
- package/dist/compat/math/add.js +26 -0
- package/dist/compat/math/ceil.js +11 -0
- package/dist/compat/math/clamp.js +17 -0
- package/dist/compat/math/divide.js +26 -0
- package/dist/compat/math/floor.js +11 -0
- package/dist/compat/math/inRange.js +32 -0
- package/dist/compat/math/max.js +22 -0
- package/dist/compat/math/maxBy.js +15 -0
- package/dist/compat/math/mean.js +12 -0
- package/dist/compat/math/meanBy.js +15 -0
- package/dist/compat/math/min.js +22 -0
- package/dist/compat/math/minBy.js +15 -0
- package/dist/compat/math/multiply.js +26 -0
- package/dist/compat/math/parseInt.js +12 -0
- package/dist/compat/math/random.js +74 -0
- package/dist/compat/math/range.js +30 -0
- package/dist/compat/math/rangeRight.js +30 -0
- package/dist/compat/math/round.js +11 -0
- package/dist/compat/math/subtract.js +26 -0
- package/dist/compat/math/sum.js +11 -0
- package/dist/compat/math/sumBy.js +29 -0
- package/dist/compat/max.js +1 -0
- package/dist/compat/maxBy.js +1 -0
- package/dist/compat/mean.js +1 -0
- package/dist/compat/meanBy.js +1 -0
- package/dist/compat/memoize.js +1 -0
- package/dist/compat/merge.js +1 -0
- package/dist/compat/mergeWith.js +1 -0
- package/dist/compat/method.js +1 -0
- package/dist/compat/methodOf.js +1 -0
- package/dist/compat/min.js +1 -0
- package/dist/compat/minBy.js +1 -0
- package/dist/compat/multiply.js +1 -0
- package/dist/compat/negate.js +1 -0
- package/dist/compat/noop.js +1 -0
- package/dist/compat/now.js +1 -0
- package/dist/compat/nth.js +1 -0
- package/dist/compat/nthArg.js +1 -0
- package/dist/compat/object/assign.js +24 -0
- package/dist/compat/object/assignIn.js +24 -0
- package/dist/compat/object/assignInWith.js +34 -0
- package/dist/compat/object/assignWith.js +34 -0
- package/dist/compat/object/at.js +31 -0
- package/dist/compat/object/clone.js +164 -0
- package/dist/compat/object/cloneDeep.js +11 -0
- package/dist/compat/object/cloneDeepWith.js +39 -0
- package/dist/compat/object/cloneWith.js +18 -0
- package/dist/compat/object/create.js +22 -0
- package/dist/compat/object/defaults.js +31 -0
- package/dist/compat/object/defaultsDeep.js +47 -0
- package/dist/compat/object/findKey.js +17 -0
- package/dist/compat/object/findLastKey.js +17 -0
- package/dist/compat/object/forIn.js +20 -0
- package/dist/compat/object/forInRight.js +25 -0
- package/dist/compat/object/forOwn.js +23 -0
- package/dist/compat/object/forOwnRight.js +23 -0
- package/dist/compat/object/fromPairs.js +18 -0
- package/dist/compat/object/functions.js +14 -0
- package/dist/compat/object/functionsIn.js +20 -0
- package/dist/compat/object/get.js +72 -0
- package/dist/compat/object/has.js +38 -0
- package/dist/compat/object/hasIn.js +38 -0
- package/dist/compat/object/invertBy.js +31 -0
- package/dist/compat/object/keys.js +36 -0
- package/dist/compat/object/keysIn.js +57 -0
- package/dist/compat/object/mapKeys.js +24 -0
- package/dist/compat/object/mapValues.js +24 -0
- package/dist/compat/object/merge.js +12 -0
- package/dist/compat/object/mergeWith.js +92 -0
- package/dist/compat/object/omit.js +37 -0
- package/dist/compat/object/omitBy.js +30 -0
- package/dist/compat/object/pick.js +53 -0
- package/dist/compat/object/pickBy.js +30 -0
- package/dist/compat/object/property.js +13 -0
- package/dist/compat/object/propertyOf.js +13 -0
- package/dist/compat/object/result.js +28 -0
- package/dist/compat/object/set.js +11 -0
- package/dist/compat/object/setWith.js +18 -0
- package/dist/compat/object/toDefaulted.js +13 -0
- package/dist/compat/object/toPairs.js +26 -0
- package/dist/compat/object/toPairsIn.js +26 -0
- package/dist/compat/object/transform.js +34 -0
- package/dist/compat/object/unset.js +72 -0
- package/dist/compat/object/update.js +11 -0
- package/dist/compat/object/updateWith.js +48 -0
- package/dist/compat/object/values.js +9 -0
- package/dist/compat/object/valuesIn.js +17 -0
- package/dist/compat/omit.js +1 -0
- package/dist/compat/omitBy.js +1 -0
- package/dist/compat/once.js +1 -0
- package/dist/compat/orderBy.js +1 -0
- package/dist/compat/over.js +1 -0
- package/dist/compat/overArgs.js +1 -0
- package/dist/compat/overEvery.js +1 -0
- package/dist/compat/overSome.js +1 -0
- package/dist/compat/pad.js +1 -0
- package/dist/compat/padEnd.js +1 -0
- package/dist/compat/padStart.js +1 -0
- package/dist/compat/parseInt.js +1 -0
- package/dist/compat/partial.js +1 -0
- package/dist/compat/partialRight.js +1 -0
- package/dist/compat/partition.js +1 -0
- package/dist/compat/pick.js +1 -0
- package/dist/compat/pickBy.js +1 -0
- package/dist/compat/predicate/conforms.js +15 -0
- package/dist/compat/predicate/conformsTo.js +24 -0
- package/dist/compat/predicate/isArguments.js +11 -0
- package/dist/compat/predicate/isArray.js +9 -0
- package/dist/compat/predicate/isArrayBuffer.js +11 -0
- package/dist/compat/predicate/isArrayLike.js +11 -0
- package/dist/compat/predicate/isArrayLikeObject.js +12 -0
- package/dist/compat/predicate/isBoolean.js +9 -0
- package/dist/compat/predicate/isBuffer.js +11 -0
- package/dist/compat/predicate/isDate.js +11 -0
- package/dist/compat/predicate/isElement.js +12 -0
- package/dist/compat/predicate/isEmpty.js +37 -0
- package/dist/compat/predicate/isEqualWith.js +27 -0
- package/dist/compat/predicate/isError.js +11 -0
- package/dist/compat/predicate/isFinite.js +9 -0
- package/dist/compat/predicate/isInteger.js +9 -0
- package/dist/compat/predicate/isMap.js +11 -0
- package/dist/compat/predicate/isMatch.js +11 -0
- package/dist/compat/predicate/isMatchWith.js +156 -0
- package/dist/compat/predicate/isNaN.js +9 -0
- package/dist/compat/predicate/isNative.js +21 -0
- package/dist/compat/predicate/isNil.js +9 -0
- package/dist/compat/predicate/isNumber.js +9 -0
- package/dist/compat/predicate/isObject.js +9 -0
- package/dist/compat/predicate/isObjectLike.js +9 -0
- package/dist/compat/predicate/isPlainObject.js +33 -0
- package/dist/compat/predicate/isRegExp.js +11 -0
- package/dist/compat/predicate/isSafeInteger.js +9 -0
- package/dist/compat/predicate/isSet.js +11 -0
- package/dist/compat/predicate/isString.js +9 -0
- package/dist/compat/predicate/isSymbol.js +9 -0
- package/dist/compat/predicate/isTypedArray.js +11 -0
- package/dist/compat/predicate/isWeakMap.js +11 -0
- package/dist/compat/predicate/isWeakSet.js +11 -0
- package/dist/compat/predicate/matches.js +15 -0
- package/dist/compat/predicate/matchesProperty.js +37 -0
- package/dist/compat/property.js +1 -0
- package/dist/compat/propertyOf.js +1 -0
- package/dist/compat/pull.js +1 -0
- package/dist/compat/pullAll.js +1 -0
- package/dist/compat/pullAllBy.js +1 -0
- package/dist/compat/pullAllWith.js +1 -0
- package/dist/compat/pullAt.js +1 -0
- package/dist/compat/random.js +1 -0
- package/dist/compat/range.js +1 -0
- package/dist/compat/rangeRight.js +1 -0
- package/dist/compat/rearg.js +1 -0
- package/dist/compat/reduce.js +1 -0
- package/dist/compat/reduceRight.js +1 -0
- package/dist/compat/reject.js +1 -0
- package/dist/compat/remove.js +1 -0
- package/dist/compat/repeat.js +1 -0
- package/dist/compat/replace.js +1 -0
- package/dist/compat/rest.js +1 -0
- package/dist/compat/result.js +1 -0
- package/dist/compat/reverse.js +1 -0
- package/dist/compat/round.js +1 -0
- package/dist/compat/sample.js +1 -0
- package/dist/compat/sampleSize.js +1 -0
- package/dist/compat/set.js +1 -0
- package/dist/compat/setWith.js +1 -0
- package/dist/compat/shuffle.js +1 -0
- package/dist/compat/size.js +1 -0
- package/dist/compat/slice.js +1 -0
- package/dist/compat/snakeCase.js +1 -0
- package/dist/compat/some.js +1 -0
- package/dist/compat/sortBy.js +1 -0
- package/dist/compat/sortedIndex.js +1 -0
- package/dist/compat/sortedIndexBy.js +1 -0
- package/dist/compat/sortedIndexOf.js +1 -0
- package/dist/compat/sortedLastIndex.js +1 -0
- package/dist/compat/sortedLastIndexBy.js +1 -0
- package/dist/compat/sortedLastIndexOf.js +1 -0
- package/dist/compat/split.js +1 -0
- package/dist/compat/spread.js +1 -0
- package/dist/compat/startCase.js +1 -0
- package/dist/compat/startsWith.js +1 -0
- package/dist/compat/string/camelCase.js +12 -0
- package/dist/compat/string/deburr.js +12 -0
- package/dist/compat/string/endsWith.js +9 -0
- package/dist/compat/string/escape.js +12 -0
- package/dist/compat/string/escapeRegExp.js +12 -0
- package/dist/compat/string/kebabCase.js +12 -0
- package/dist/compat/string/lowerCase.js +12 -0
- package/dist/compat/string/lowerFirst.js +12 -0
- package/dist/compat/string/pad.js +12 -0
- package/dist/compat/string/padEnd.js +11 -0
- package/dist/compat/string/padStart.js +11 -0
- package/dist/compat/string/repeat.js +19 -0
- package/dist/compat/string/replace.js +14 -0
- package/dist/compat/string/snakeCase.js +12 -0
- package/dist/compat/string/split.js +11 -0
- package/dist/compat/string/startCase.js +26 -0
- package/dist/compat/string/startsWith.js +9 -0
- package/dist/compat/string/template.js +91 -0
- package/dist/compat/string/toLower.js +11 -0
- package/dist/compat/string/toUpper.js +11 -0
- package/dist/compat/string/trim.js +29 -0
- package/dist/compat/string/trimEnd.js +29 -0
- package/dist/compat/string/trimStart.js +29 -0
- package/dist/compat/string/truncate.js +52 -0
- package/dist/compat/string/unescape.js +12 -0
- package/dist/compat/string/upperCase.js +12 -0
- package/dist/compat/string/upperFirst.js +12 -0
- package/dist/compat/string/words.js +35 -0
- package/dist/compat/stubArray.js +1 -0
- package/dist/compat/stubFalse.js +1 -0
- package/dist/compat/stubObject.js +1 -0
- package/dist/compat/stubString.js +1 -0
- package/dist/compat/stubTrue.js +1 -0
- package/dist/compat/subtract.js +1 -0
- package/dist/compat/sum.js +1 -0
- package/dist/compat/sumBy.js +1 -0
- package/dist/compat/tail.js +1 -0
- package/dist/compat/take.js +1 -0
- package/dist/compat/takeRight.js +1 -0
- package/dist/compat/takeRightWhile.js +1 -0
- package/dist/compat/takeWhile.js +1 -0
- package/dist/compat/template.js +1 -0
- package/dist/compat/templateSettings.js +1 -0
- package/dist/compat/throttle.js +1 -0
- package/dist/compat/times.js +1 -0
- package/dist/compat/toArray.js +1 -0
- package/dist/compat/toDefaulted.js +1 -0
- package/dist/compat/toFinite.js +1 -0
- package/dist/compat/toInteger.js +1 -0
- package/dist/compat/toLength.js +1 -0
- package/dist/compat/toLower.js +1 -0
- package/dist/compat/toNumber.js +1 -0
- package/dist/compat/toPairs.js +1 -0
- package/dist/compat/toPairsIn.js +1 -0
- package/dist/compat/toPath.js +1 -0
- package/dist/compat/toPlainObject.js +1 -0
- package/dist/compat/toSafeInteger.js +1 -0
- package/dist/compat/toString.js +1 -0
- package/dist/compat/toUpper.js +1 -0
- package/dist/compat/toolkit.js +14 -0
- package/dist/compat/transform.js +1 -0
- package/dist/compat/trim.js +1 -0
- package/dist/compat/trimEnd.js +1 -0
- package/dist/compat/trimStart.js +1 -0
- package/dist/compat/truncate.js +1 -0
- package/dist/compat/unary.js +1 -0
- package/dist/compat/unescape.js +1 -0
- package/dist/compat/union.js +1 -0
- package/dist/compat/unionBy.js +1 -0
- package/dist/compat/unionWith.js +1 -0
- package/dist/compat/uniq.js +1 -0
- package/dist/compat/uniqBy.js +1 -0
- package/dist/compat/uniqWith.js +1 -0
- package/dist/compat/uniqueId.js +1 -0
- package/dist/compat/unset.js +1 -0
- package/dist/compat/unzip.js +1 -0
- package/dist/compat/unzipWith.js +1 -0
- package/dist/compat/update.js +1 -0
- package/dist/compat/updateWith.js +1 -0
- package/dist/compat/upperCase.js +1 -0
- package/dist/compat/upperFirst.js +1 -0
- package/dist/compat/util/bindAll.js +47 -0
- package/dist/compat/util/cond.js +30 -0
- package/dist/compat/util/constant.js +9 -0
- package/dist/compat/util/defaultTo.js +12 -0
- package/dist/compat/util/eq.js +9 -0
- package/dist/compat/util/gt.js +14 -0
- package/dist/compat/util/gte.js +14 -0
- package/dist/compat/util/invoke.js +52 -0
- package/dist/compat/util/iteratee.js +32 -0
- package/dist/compat/util/lt.js +14 -0
- package/dist/compat/util/lte.js +14 -0
- package/dist/compat/util/method.js +13 -0
- package/dist/compat/util/methodOf.js +13 -0
- package/dist/compat/util/now.js +9 -0
- package/dist/compat/util/over.js +17 -0
- package/dist/compat/util/overEvery.js +27 -0
- package/dist/compat/util/overSome.js +27 -0
- package/dist/compat/util/stubArray.js +9 -0
- package/dist/compat/util/stubFalse.js +9 -0
- package/dist/compat/util/stubObject.js +9 -0
- package/dist/compat/util/stubString.js +9 -0
- package/dist/compat/util/stubTrue.js +9 -0
- package/dist/compat/util/times.js +19 -0
- package/dist/compat/util/toArray.js +21 -0
- package/dist/compat/util/toFinite.js +19 -0
- package/dist/compat/util/toInteger.js +13 -0
- package/dist/compat/util/toLength.js +16 -0
- package/dist/compat/util/toNumber.js +14 -0
- package/dist/compat/util/toPath.js +72 -0
- package/dist/compat/util/toPlainObject.js +28 -0
- package/dist/compat/util/toSafeInteger.js +16 -0
- package/dist/compat/util/toString.js +22 -0
- package/dist/compat/util/uniqueId.js +11 -0
- package/dist/compat/values.js +1 -0
- package/dist/compat/valuesIn.js +1 -0
- package/dist/compat/without.js +1 -0
- package/dist/compat/words.js +1 -0
- package/dist/compat/wrap.js +1 -0
- package/dist/compat/xor.js +1 -0
- package/dist/compat/xorBy.js +1 -0
- package/dist/compat/xorWith.js +1 -0
- package/dist/compat/zip.js +1 -0
- package/dist/compat/zipObject.js +1 -0
- package/dist/compat/zipObjectDeep.js +1 -0
- package/dist/compat/zipWith.js +1 -0
- package/dist/{_chunk/AbortError-Cg4ZQ1.js → error/AbortError.js} +2 -0
- package/dist/error/TimeoutError.js +12 -0
- package/dist/error/index.js +4 -8
- package/dist/function/after.js +18 -0
- package/dist/function/ary.js +11 -0
- package/dist/function/asyncNoop.js +7 -0
- package/dist/function/before.js +18 -0
- package/dist/function/curry.js +25 -0
- package/dist/function/curryRight.js +25 -0
- package/dist/function/debounce.js +67 -0
- package/dist/function/flow.js +15 -0
- package/dist/function/flowRight.js +11 -0
- package/dist/function/identity.js +9 -0
- package/dist/function/index.js +44 -153
- package/dist/function/memoize.js +20 -0
- package/dist/function/negate.js +9 -0
- package/dist/function/noop.js +7 -0
- package/dist/function/once.js +17 -0
- package/dist/function/partial.js +26 -0
- package/dist/function/partialRight.js +28 -0
- package/dist/function/rest.js +16 -0
- package/dist/function/retry.js +40 -0
- package/dist/function/spread.js +11 -0
- package/dist/function/throttle.js +27 -0
- package/dist/function/unary.js +11 -0
- package/dist/index.js +339 -188
- package/dist/math/clamp.js +12 -0
- package/dist/math/inRange.js +16 -0
- package/dist/math/index.js +28 -66
- package/dist/math/mean.js +11 -0
- package/dist/math/meanBy.js +12 -0
- package/dist/math/median.js +19 -0
- package/dist/math/medianBy.js +12 -0
- package/dist/{_chunk/randomInt-CF7bZK.js → math/random.js} +2 -5
- package/dist/math/randomInt.js +11 -0
- package/dist/math/range.js +21 -0
- package/dist/math/rangeRight.js +21 -0
- package/dist/math/round.js +13 -0
- package/dist/math/sum.js +13 -0
- package/dist/math/sumBy.js +13 -0
- package/dist/object/clone.js +49 -0
- package/dist/object/cloneDeep.js +11 -0
- package/dist/object/cloneDeepWith.js +160 -0
- package/dist/object/findKey.js +10 -0
- package/dist/object/flattenObject.js +30 -0
- package/dist/object/index.js +37 -182
- package/dist/object/invert.js +16 -0
- package/dist/object/mapKeys.js +16 -0
- package/dist/object/mapValues.js +16 -0
- package/dist/object/merge.js +36 -0
- package/dist/object/mergeWith.js +30 -0
- package/dist/object/omit.js +14 -0
- package/dist/object/omitBy.js +18 -0
- package/dist/object/pick.js +16 -0
- package/dist/object/pickBy.js +18 -0
- package/dist/object/toCamelCaseKeys.js +27 -0
- package/dist/object/toMerged.js +12 -0
- package/dist/object/toSnakeCaseKeys.js +27 -0
- package/dist/predicate/index.js +61 -125
- package/dist/predicate/isArrayBuffer.js +9 -0
- package/dist/predicate/isBlob.js +12 -0
- package/dist/predicate/isBoolean.js +9 -0
- package/dist/predicate/isBrowser.js +9 -0
- package/dist/predicate/isBuffer.js +9 -0
- package/dist/predicate/isDate.js +9 -0
- package/dist/predicate/isEqual.js +12 -0
- package/dist/{_chunk/isWeakSet-403Sh5.js → predicate/isEqualWith.js} +40 -115
- package/dist/predicate/isError.js +9 -0
- package/dist/predicate/isFile.js +14 -0
- package/dist/predicate/isFunction.js +9 -0
- package/dist/predicate/isJSON.js +18 -0
- package/dist/predicate/isJSONValue.js +48 -0
- package/dist/predicate/isLength.js +9 -0
- package/dist/predicate/isMap.js +9 -0
- package/dist/predicate/isNil.js +9 -0
- package/dist/predicate/isNode.js +9 -0
- package/dist/predicate/isNotNil.js +9 -0
- package/dist/predicate/isNull.js +9 -0
- package/dist/predicate/isPlainObject.js +19 -0
- package/dist/predicate/isPrimitive.js +9 -0
- package/dist/predicate/isPromise.js +9 -0
- package/dist/predicate/isRegExp.js +9 -0
- package/dist/predicate/isSet.js +9 -0
- package/dist/predicate/isString.js +9 -0
- package/dist/predicate/isSymbol.js +9 -0
- package/dist/predicate/isTypedArray.js +9 -0
- package/dist/predicate/isUndefined.js +9 -0
- package/dist/predicate/isWeakMap.js +9 -0
- package/dist/predicate/isWeakSet.js +9 -0
- package/dist/{_chunk/delay-_VMfFa.js → promise/delay.js} +3 -1
- package/dist/promise/index.js +9 -55
- package/dist/promise/mutex.js +20 -0
- package/dist/promise/semaphore.js +34 -0
- package/dist/promise/timeout.js +13 -0
- package/dist/promise/withTimeout.js +11 -0
- package/dist/string/camelCase.js +17 -0
- package/dist/string/capitalize.js +9 -0
- package/dist/string/constantCase.js +12 -0
- package/dist/string/deburr.js +49 -0
- package/dist/string/escape.js +16 -0
- package/dist/string/escapeRegExp.js +9 -0
- package/dist/string/index.js +40 -46
- package/dist/string/kebabCase.js +12 -0
- package/dist/string/lowerCase.js +12 -0
- package/dist/string/lowerFirst.js +9 -0
- package/dist/string/pad.js +9 -0
- package/dist/string/pascalCase.js +13 -0
- package/dist/string/reverseString.js +9 -0
- package/dist/string/snakeCase.js +12 -0
- package/dist/string/startCase.js +20 -0
- package/dist/string/trim.js +15 -0
- package/dist/string/trimEnd.js +29 -0
- package/dist/string/trimStart.js +26 -0
- package/dist/string/unescape.js +16 -0
- package/dist/string/upperCase.js +19 -0
- package/dist/string/upperFirst.js +9 -0
- package/dist/string/words.js +11 -0
- package/dist/util/attempt.js +14 -0
- package/dist/util/attemptAsync.js +15 -0
- package/dist/util/index.js +7 -30
- package/dist/util/invariant.js +15 -0
- package/error.js +1 -0
- package/function.js +1 -0
- package/math.js +1 -0
- package/object.js +1 -0
- package/package.json +16 -2
- package/predicate.js +1 -0
- package/promise.js +1 -0
- package/string.js +1 -0
- package/util.js +1 -0
- package/dist/_chunk/isPlainObject-DINLyA.js +0 -281
- package/dist/_chunk/noop-2IwLUk.js +0 -5
- package/dist/_chunk/range-DSpBDL.js +0 -59
- package/dist/_chunk/snakeCase-6cG1f4.js +0 -29
- package/dist/_chunk/unary-BVQ0iC.js +0 -188
- package/dist/_chunk/upperFirst-Cx78bs.js +0 -173
- package/dist/_chunk/zip-Cyyp17.js +0 -421
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require eslint/bin/eslint.js
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
// Defer to the real eslint/bin/eslint.js your application uses
|
|
32
|
+
module.exports = wrapWithUserWrapper(absRequire(`eslint/bin/eslint.js`));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require eslint
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
// Defer to the real eslint your application uses
|
|
32
|
+
module.exports = wrapWithUserWrapper(absRequire(`eslint`));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require eslint/config
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
// Defer to the real eslint/config your application uses
|
|
32
|
+
module.exports = wrapWithUserWrapper(absRequire(`eslint/config`));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require eslint/universal
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
// Defer to the real eslint/universal your application uses
|
|
32
|
+
module.exports = wrapWithUserWrapper(absRequire(`eslint/universal`));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require eslint/use-at-your-own-risk
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
// Defer to the real eslint/use-at-your-own-risk your application uses
|
|
32
|
+
module.exports = wrapWithUserWrapper(absRequire(`eslint/use-at-your-own-risk`));
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require typescript/lib/tsc.js
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
// Defer to the real typescript/lib/tsc.js your application uses
|
|
32
|
+
module.exports = wrapWithUserWrapper(absRequire(`typescript/lib/tsc.js`));
|
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const {existsSync} = require(`fs`);
|
|
4
|
+
const {createRequire, register} = require(`module`);
|
|
5
|
+
const {resolve} = require(`path`);
|
|
6
|
+
const {pathToFileURL} = require(`url`);
|
|
7
|
+
|
|
8
|
+
const relPnpApiPath = "../../../../.pnp.cjs";
|
|
9
|
+
|
|
10
|
+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
|
|
11
|
+
const absUserWrapperPath = resolve(__dirname, `./sdk.user.cjs`);
|
|
12
|
+
const absRequire = createRequire(absPnpApiPath);
|
|
13
|
+
|
|
14
|
+
const absPnpLoaderPath = resolve(absPnpApiPath, `../.pnp.loader.mjs`);
|
|
15
|
+
const isPnpLoaderEnabled = existsSync(absPnpLoaderPath);
|
|
16
|
+
|
|
17
|
+
if (existsSync(absPnpApiPath)) {
|
|
18
|
+
if (!process.versions.pnp) {
|
|
19
|
+
// Setup the environment to be able to require typescript/lib/tsserver.js
|
|
20
|
+
require(absPnpApiPath).setup();
|
|
21
|
+
if (isPnpLoaderEnabled && register) {
|
|
22
|
+
register(pathToFileURL(absPnpLoaderPath));
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const wrapWithUserWrapper = existsSync(absUserWrapperPath)
|
|
28
|
+
? exports => absRequire(absUserWrapperPath)(exports)
|
|
29
|
+
: exports => exports;
|
|
30
|
+
|
|
31
|
+
const moduleWrapper = exports => {
|
|
32
|
+
return wrapWithUserWrapper(moduleWrapperFn(exports));
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
const moduleWrapperFn = tsserver => {
|
|
36
|
+
if (!process.versions.pnp) {
|
|
37
|
+
return tsserver;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
const {isAbsolute} = require(`path`);
|
|
41
|
+
const pnpApi = require(`pnpapi`);
|
|
42
|
+
|
|
43
|
+
const isVirtual = str => str.match(/\/(\$\$virtual|__virtual__)\//);
|
|
44
|
+
const isPortal = str => str.startsWith("portal:/");
|
|
45
|
+
const normalize = str => str.replace(/\\/g, `/`).replace(/^\/?/, `/`);
|
|
46
|
+
|
|
47
|
+
const dependencyTreeRoots = new Set(pnpApi.getDependencyTreeRoots().map(locator => {
|
|
48
|
+
return `${locator.name}@${locator.reference}`;
|
|
49
|
+
}));
|
|
50
|
+
|
|
51
|
+
// VSCode sends the zip paths to TS using the "zip://" prefix, that TS
|
|
52
|
+
// doesn't understand. This layer makes sure to remove the protocol
|
|
53
|
+
// before forwarding it to TS, and to add it back on all returned paths.
|
|
54
|
+
|
|
55
|
+
function toEditorPath(str) {
|
|
56
|
+
// We add the `zip:` prefix to both `.zip/` paths and virtual paths
|
|
57
|
+
if (isAbsolute(str) && !str.match(/^\^?(zip:|\/zip\/)/) && (str.match(/\.zip\//) || isVirtual(str))) {
|
|
58
|
+
// We also take the opportunity to turn virtual paths into physical ones;
|
|
59
|
+
// this makes it much easier to work with workspaces that list peer
|
|
60
|
+
// dependencies, since otherwise Ctrl+Click would bring us to the virtual
|
|
61
|
+
// file instances instead of the real ones.
|
|
62
|
+
//
|
|
63
|
+
// We only do this to modules owned by the the dependency tree roots.
|
|
64
|
+
// This avoids breaking the resolution when jumping inside a vendor
|
|
65
|
+
// with peer dep (otherwise jumping into react-dom would show resolution
|
|
66
|
+
// errors on react).
|
|
67
|
+
//
|
|
68
|
+
const resolved = isVirtual(str) ? pnpApi.resolveVirtual(str) : str;
|
|
69
|
+
if (resolved) {
|
|
70
|
+
const locator = pnpApi.findPackageLocator(resolved);
|
|
71
|
+
if (locator && (dependencyTreeRoots.has(`${locator.name}@${locator.reference}`) || isPortal(locator.reference))) {
|
|
72
|
+
str = resolved;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
str = normalize(str);
|
|
77
|
+
|
|
78
|
+
if (str.match(/\.zip\//)) {
|
|
79
|
+
switch (hostInfo) {
|
|
80
|
+
// Absolute VSCode `Uri.fsPath`s need to start with a slash.
|
|
81
|
+
// VSCode only adds it automatically for supported schemes,
|
|
82
|
+
// so we have to do it manually for the `zip` scheme.
|
|
83
|
+
// The path needs to start with a caret otherwise VSCode doesn't handle the protocol
|
|
84
|
+
//
|
|
85
|
+
// Ref: https://github.com/microsoft/vscode/issues/105014#issuecomment-686760910
|
|
86
|
+
//
|
|
87
|
+
// 2021-10-08: VSCode changed the format in 1.61.
|
|
88
|
+
// Before | ^zip:/c:/foo/bar.zip/package.json
|
|
89
|
+
// After | ^/zip//c:/foo/bar.zip/package.json
|
|
90
|
+
//
|
|
91
|
+
// 2022-04-06: VSCode changed the format in 1.66.
|
|
92
|
+
// Before | ^/zip//c:/foo/bar.zip/package.json
|
|
93
|
+
// After | ^/zip/c:/foo/bar.zip/package.json
|
|
94
|
+
//
|
|
95
|
+
// 2022-05-06: VSCode changed the format in 1.68
|
|
96
|
+
// Before | ^/zip/c:/foo/bar.zip/package.json
|
|
97
|
+
// After | ^/zip//c:/foo/bar.zip/package.json
|
|
98
|
+
//
|
|
99
|
+
case `vscode <1.61`: {
|
|
100
|
+
str = `^zip:${str}`;
|
|
101
|
+
} break;
|
|
102
|
+
|
|
103
|
+
case `vscode <1.66`: {
|
|
104
|
+
str = `^/zip/${str}`;
|
|
105
|
+
} break;
|
|
106
|
+
|
|
107
|
+
case `vscode <1.68`: {
|
|
108
|
+
str = `^/zip${str}`;
|
|
109
|
+
} break;
|
|
110
|
+
|
|
111
|
+
case `vscode`: {
|
|
112
|
+
str = `^/zip/${str}`;
|
|
113
|
+
} break;
|
|
114
|
+
|
|
115
|
+
// To make "go to definition" work,
|
|
116
|
+
// We have to resolve the actual file system path from virtual path
|
|
117
|
+
// and convert scheme to supported by [vim-rzip](https://github.com/lbrayner/vim-rzip)
|
|
118
|
+
case `coc-nvim`: {
|
|
119
|
+
str = normalize(resolved).replace(/\.zip\//, `.zip::`);
|
|
120
|
+
str = resolve(`zipfile:${str}`);
|
|
121
|
+
} break;
|
|
122
|
+
|
|
123
|
+
// Support neovim native LSP and [typescript-language-server](https://github.com/theia-ide/typescript-language-server)
|
|
124
|
+
// We have to resolve the actual file system path from virtual path,
|
|
125
|
+
// everything else is up to neovim
|
|
126
|
+
case `neovim`: {
|
|
127
|
+
str = normalize(resolved).replace(/\.zip\//, `.zip::`);
|
|
128
|
+
str = `zipfile://${str}`;
|
|
129
|
+
} break;
|
|
130
|
+
|
|
131
|
+
default: {
|
|
132
|
+
str = `zip:${str}`;
|
|
133
|
+
} break;
|
|
134
|
+
}
|
|
135
|
+
} else {
|
|
136
|
+
str = str.replace(/^\/?/, process.platform === `win32` ? `` : `/`);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
return str;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
function fromEditorPath(str) {
|
|
144
|
+
switch (hostInfo) {
|
|
145
|
+
case `coc-nvim`: {
|
|
146
|
+
str = str.replace(/\.zip::/, `.zip/`);
|
|
147
|
+
// The path for coc-nvim is in format of /<pwd>/zipfile:/<pwd>/.yarn/...
|
|
148
|
+
// So in order to convert it back, we use .* to match all the thing
|
|
149
|
+
// before `zipfile:`
|
|
150
|
+
return process.platform === `win32`
|
|
151
|
+
? str.replace(/^.*zipfile:\//, ``)
|
|
152
|
+
: str.replace(/^.*zipfile:/, ``);
|
|
153
|
+
} break;
|
|
154
|
+
|
|
155
|
+
case `neovim`: {
|
|
156
|
+
str = str.replace(/\.zip::/, `.zip/`);
|
|
157
|
+
// The path for neovim is in format of zipfile:///<pwd>/.yarn/...
|
|
158
|
+
return str.replace(/^zipfile:\/\//, ``);
|
|
159
|
+
} break;
|
|
160
|
+
|
|
161
|
+
case `vscode`:
|
|
162
|
+
default: {
|
|
163
|
+
return str.replace(/^\^?(zip:|\/zip(\/ts-nul-authority)?)\/+/, process.platform === `win32` ? `` : `/`)
|
|
164
|
+
} break;
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
// Force enable 'allowLocalPluginLoads'
|
|
169
|
+
// TypeScript tries to resolve plugins using a path relative to itself
|
|
170
|
+
// which doesn't work when using the global cache
|
|
171
|
+
// https://github.com/microsoft/TypeScript/blob/1b57a0395e0bff191581c9606aab92832001de62/src/server/project.ts#L2238
|
|
172
|
+
// VSCode doesn't want to enable 'allowLocalPluginLoads' due to security concerns but
|
|
173
|
+
// TypeScript already does local loads and if this code is running the user trusts the workspace
|
|
174
|
+
// https://github.com/microsoft/vscode/issues/45856
|
|
175
|
+
const ConfiguredProject = tsserver.server.ConfiguredProject;
|
|
176
|
+
const {enablePluginsWithOptions: originalEnablePluginsWithOptions} = ConfiguredProject.prototype;
|
|
177
|
+
ConfiguredProject.prototype.enablePluginsWithOptions = function() {
|
|
178
|
+
this.projectService.allowLocalPluginLoads = true;
|
|
179
|
+
return originalEnablePluginsWithOptions.apply(this, arguments);
|
|
180
|
+
};
|
|
181
|
+
|
|
182
|
+
// And here is the point where we hijack the VSCode <-> TS communications
|
|
183
|
+
// by adding ourselves in the middle. We locate everything that looks
|
|
184
|
+
// like an absolute path of ours and normalize it.
|
|
185
|
+
|
|
186
|
+
const Session = tsserver.server.Session;
|
|
187
|
+
const {onMessage: originalOnMessage, send: originalSend} = Session.prototype;
|
|
188
|
+
let hostInfo = `unknown`;
|
|
189
|
+
|
|
190
|
+
Object.assign(Session.prototype, {
|
|
191
|
+
onMessage(/** @type {string | object} */ message) {
|
|
192
|
+
const isStringMessage = typeof message === 'string';
|
|
193
|
+
const parsedMessage = isStringMessage ? JSON.parse(message) : message;
|
|
194
|
+
|
|
195
|
+
if (
|
|
196
|
+
parsedMessage != null &&
|
|
197
|
+
typeof parsedMessage === `object` &&
|
|
198
|
+
parsedMessage.arguments &&
|
|
199
|
+
typeof parsedMessage.arguments.hostInfo === `string`
|
|
200
|
+
) {
|
|
201
|
+
hostInfo = parsedMessage.arguments.hostInfo;
|
|
202
|
+
if (hostInfo === `vscode` && process.env.VSCODE_IPC_HOOK) {
|
|
203
|
+
const [, major, minor] = (process.env.VSCODE_IPC_HOOK.match(
|
|
204
|
+
// The RegExp from https://semver.org/ but without the caret at the start
|
|
205
|
+
/(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$/
|
|
206
|
+
) ?? []).map(Number)
|
|
207
|
+
|
|
208
|
+
if (major === 1) {
|
|
209
|
+
if (minor < 61) {
|
|
210
|
+
hostInfo += ` <1.61`;
|
|
211
|
+
} else if (minor < 66) {
|
|
212
|
+
hostInfo += ` <1.66`;
|
|
213
|
+
} else if (minor < 68) {
|
|
214
|
+
hostInfo += ` <1.68`;
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
const processedMessageJSON = JSON.stringify(parsedMessage, (key, value) => {
|
|
221
|
+
return typeof value === 'string' ? fromEditorPath(value) : value;
|
|
222
|
+
});
|
|
223
|
+
|
|
224
|
+
return originalOnMessage.call(
|
|
225
|
+
this,
|
|
226
|
+
isStringMessage ? processedMessageJSON : JSON.parse(processedMessageJSON)
|
|
227
|
+
);
|
|
228
|
+
},
|
|
229
|
+
|
|
230
|
+
send(/** @type {any} */ msg) {
|
|
231
|
+
return originalSend.call(this, JSON.parse(JSON.stringify(msg, (key, value) => {
|
|
232
|
+
return typeof value === `string` ? toEditorPath(value) : value;
|
|
233
|
+
})));
|
|
234
|
+
}
|
|
235
|
+
});
|
|
236
|
+
|
|
237
|
+
return tsserver;
|
|
238
|
+
};
|
|
239
|
+
|
|
240
|
+
const [major, minor] = absRequire(`typescript/package.json`).version.split(`.`, 2).map(value => parseInt(value, 10));
|
|
241
|
+
// In TypeScript@>=5.5 the tsserver uses the public TypeScript API so that needs to be patched as well.
|
|
242
|
+
// Ref https://github.com/microsoft/TypeScript/pull/55326
|
|
243
|
+
if (major > 5 || (major === 5 && minor >= 5)) {
|
|
244
|
+
moduleWrapper(absRequire(`typescript`));
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
// Defer to the real typescript/lib/tsserver.js your application uses
|
|
248
|
+
module.exports = moduleWrapper(absRequire(`typescript/lib/tsserver.js`));
|