massaman 0.3.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (71) hide show
  1. package/README.md +4 -4
  2. package/dist/array/index.d.mts +2 -2
  3. package/dist/array/index.mjs +2 -2
  4. package/dist/{array-C8MqjyiP.mjs → array-glQHknc3.mjs} +3 -3
  5. package/dist/{array-C8MqjyiP.mjs.map → array-glQHknc3.mjs.map} +1 -1
  6. package/dist/bigint/index.d.mts +2 -0
  7. package/dist/bigint/index.mjs +2 -0
  8. package/dist/control/index.d.mts +3 -3
  9. package/dist/control/index.mjs +1 -1
  10. package/dist/{control-Dg2fwHB7.mjs → control-DCdm8IH6.mjs} +1 -1
  11. package/dist/{control-Dg2fwHB7.mjs.map → control-DCdm8IH6.mjs.map} +1 -1
  12. package/dist/conversion/index.d.mts +1 -1
  13. package/dist/conversion/index.mjs +1 -1
  14. package/dist/{conversion-ByBXBR5i.mjs → conversion-BB912-15.mjs} +1 -1
  15. package/dist/{conversion-ByBXBR5i.mjs.map → conversion-BB912-15.mjs.map} +1 -1
  16. package/dist/fp/index.d.mts +2 -0
  17. package/dist/fp/index.mjs +2 -0
  18. package/dist/function/index.d.mts +2 -2
  19. package/dist/function/index.mjs +1 -1
  20. package/dist/{function-2-6QB4m7.mjs → function-Brosl7-Y.mjs} +1 -1
  21. package/dist/{function-2-6QB4m7.mjs.map → function-Brosl7-Y.mjs.map} +1 -1
  22. package/dist/{index-mfIoxwxy.d.mts → index-BPYJOreI.d.mts} +3 -4
  23. package/dist/index-BPYJOreI.d.mts.map +1 -0
  24. package/dist/{index-BjmDP8W9.d.mts → index-C7dxY5U-.d.mts} +1 -1
  25. package/dist/index-C7dxY5U-.d.mts.map +1 -0
  26. package/dist/{index-Bp3ol0vr.d.mts → index-D5q3I26j.d.mts} +2 -3
  27. package/dist/index-D5q3I26j.d.mts.map +1 -0
  28. package/dist/{index-g2aw5tc_.d.mts → index-D7DGVrkN.d.mts} +3 -4
  29. package/dist/index-D7DGVrkN.d.mts.map +1 -0
  30. package/dist/index-DTrYN2UY.d.mts +20 -0
  31. package/dist/index-DTrYN2UY.d.mts.map +1 -0
  32. package/dist/index-DcVpX2Bb.d.mts +43 -0
  33. package/dist/index-DcVpX2Bb.d.mts.map +1 -0
  34. package/dist/{index-D5l6I7QH.d.mts → index-DlZyDxI_.d.mts} +1 -2
  35. package/dist/index-DlZyDxI_.d.mts.map +1 -0
  36. package/dist/index.d.mts +12 -12
  37. package/dist/index.mjs +11 -11
  38. package/dist/match/index.d.mts +2 -2
  39. package/dist/match/index.mjs +1 -1
  40. package/dist/match-fBetfaIa.mjs +49 -0
  41. package/dist/match-fBetfaIa.mjs.map +1 -0
  42. package/dist/math/index.d.mts +2 -2
  43. package/dist/math/index.mjs +2 -2
  44. package/dist/object/index.d.mts +2 -2
  45. package/dist/object/index.mjs +2 -2
  46. package/dist/object-CILtZbTT.mjs +27 -0
  47. package/dist/{object-BHnp9Sr9.mjs.map → object-CILtZbTT.mjs.map} +1 -1
  48. package/dist/predicate/index.d.mts +2 -2
  49. package/dist/predicate/index.mjs +2 -2
  50. package/dist/{predicate-DtTBffBT.mjs → predicate-CleUejOb.mjs} +3 -3
  51. package/dist/{predicate-DtTBffBT.mjs.map → predicate-CleUejOb.mjs.map} +1 -1
  52. package/dist/promise/index.d.mts +2 -2
  53. package/dist/promise/index.mjs +2 -2
  54. package/dist/string/index.d.mts +2 -2
  55. package/dist/string/index.mjs +2 -2
  56. package/dist/{types-X6LqLWno.d.mts → types-BsimcHZS.d.mts} +1 -1
  57. package/dist/types-BsimcHZS.d.mts.map +1 -0
  58. package/package.json +17 -10
  59. package/dist/index-BjmDP8W9.d.mts.map +0 -1
  60. package/dist/index-Bp3ol0vr.d.mts.map +0 -1
  61. package/dist/index-D5l6I7QH.d.mts.map +0 -1
  62. package/dist/index-DtnKhaAD.d.mts +0 -39
  63. package/dist/index-DtnKhaAD.d.mts.map +0 -1
  64. package/dist/index-g2aw5tc_.d.mts.map +0 -1
  65. package/dist/index-keGHab-v.d.mts +0 -20
  66. package/dist/index-keGHab-v.d.mts.map +0 -1
  67. package/dist/index-mfIoxwxy.d.mts.map +0 -1
  68. package/dist/match-CG_v2C4Q.mjs +0 -44
  69. package/dist/match-CG_v2C4Q.mjs.map +0 -1
  70. package/dist/object-BHnp9Sr9.mjs +0 -27
  71. package/dist/types-X6LqLWno.d.mts.map +0 -1
package/dist/index.d.mts CHANGED
@@ -1,13 +1,13 @@
1
- import { $ as unionWith, A as last, B as remove, C as initial, D as isSubset, E as intersectionWith, F as orderBy, G as tail, H as sampleSize, I as partition, J as takeRightWhile, K as take, L as pull, M as mapAsync, N as maxBy, O as isSubsetWith, P as minBy, Q as unionBy, R as pullAt, S as head, T as intersectionBy, U as shuffle, V as sample, W as sortBy, X as toFilled, Y as takeWhile, Z as union, _ as flatten, _t as scan, a as difference, at as windowed, b as forEachRight, bt as adjust, c as drop, ct as xorBy, d as dropWhile, dt as zipObject, et as uniq, f as fill, ft as zipWith, g as flatMapDeep, gt as sortWith, h as flatMapAsync, ht as descend, i as countBy, it as unzipWith, j as limitAsync, k as keyBy, l as dropRight, lt as xorWith, m as flatMap, mt as ascend, n as chunk, nt as uniqWith, o as differenceBy, ot as without, p as filterAsync, pt as unfold, q as takeRight, r as compact, rt as unzip, s as differenceWith, st as xor, t as at, tt as uniqBy, u as dropRightWhile, ut as zip, v as flattenDeep, vt as reduceWhile, w as intersection, x as groupBy, y as forEachAsync, yt as dropRepeats, z as reduceAsync } from "./index-mfIoxwxy.mjs";
2
- import { r as Result } from "./types-X6LqLWno.mjs";
3
- import { a as todo, c as isOk, d as attempt, f as attemptAsync, i as unimplemented, l as ok, n as invariant, o as err, r as unreachable, s as isErr, t as assert, u as unwrap } from "./index-Bp3ol0vr.mjs";
4
- import { a as toFinite, c as toString, i as toError, n as toArray, o as toInteger, r as toBoolean, s as toNumber, t as stringify } from "./index-BjmDP8W9.mjs";
1
+ import { $ as union, A as isSubset, B as pullAt, C as forEachRight, D as intersection, E as initial, F as maxBy, G as shuffle, H as remove, I as minBy, J as take, K as sortBy, L as orderBy, M as keyBy, N as last, O as intersectionBy, P as mapAsync, Q as toFilled, R as partition, S as forEachAsync, St as adjust, T as head, U as sample, V as reduceAsync, W as sampleSize, X as takeRightWhile, Y as takeRight, Z as takeWhile, _ as flatMap, _t as descend, a as combinations, at as unzip, b as flatten, bt as reduceWhile, c as difference, ct as without, d as drop, dt as xorWith, et as unionBy, f as dropRight, ft as zip, g as filterAsync, gt as ascend, h as fill, ht as unfold, i as chunkBy, it as uniqWith, j as isSubsetWith, k as intersectionWith, l as differenceBy, lt as xor, m as dropWhile, mt as zipWith, n as cartesianProduct, nt as uniq, o as compact, ot as unzipWith, p as dropRightWhile, pt as zipObject, q as tail, r as chunk, rt as uniqBy, s as countBy, st as windowed, t as at, tt as unionWith, u as differenceWith, ut as xorBy, v as flatMapAsync, vt as sortWith, w as groupBy, x as flattenDeep, xt as dropRepeats, y as flatMapDeep, yt as scan, z as pull } from "./index-BPYJOreI.mjs";
2
+ import { r as Result } from "./types-BsimcHZS.mjs";
3
+ import { a as todo, c as isOk, d as attempt, f as attemptAsync, i as unimplemented, l as ok, n as invariant, o as err, r as unreachable, s as isErr, t as assert, u as unwrap } from "./index-D5q3I26j.mjs";
4
+ import { a as toFinite, c as toString, i as toError, n as toArray, o as toInteger, r as toBoolean, s as toNumber, t as stringify } from "./index-C7dxY5U-.mjs";
5
5
  import { AbortError, TimeoutError } from "./error/index.mjs";
6
- import { A as unless, C as retry, D as flowAsync, E as unary, M as call, N as callAsync, O as tap, S as rest, T as throttle, _ as negate, a as ThrottledFunction, b as partial, c as asyncNoop, d as curryRight, f as debounce, g as memoize, h as identity, i as ThrottleOptions, j as when, k as ifElse, l as before, m as flowRight, n as DebouncedFunction, o as after, p as flow, r as MemoizeCache, s as ary, t as DebounceOptions, u as curry, v as noop, w as spread, x as partialRight, y as once } from "./index-D5l6I7QH.mjs";
7
- import { clamp, inRange, mean, meanBy, median, medianBy, random, randomInt, range, rangeRight, round, sum, sumBy } from "./math/index.mjs";
8
- import { _ as toSnakeCaseKeys, a as flattenObject, c as mapValues, d as omit, f as omitBy, g as toMerged, h as toCamelCaseKeys, i as findKey, l as merge, m as pickBy, n as cloneDeep, o as invert, p as pick, r as cloneDeepWith, s as mapKeys, t as clone, u as mergeWith, v as evolve } from "./index-keGHab-v.mjs";
9
- import { A as isSymbol, B as isNotEmpty, C as isNumber, D as isRegExp, E as isPromise, F as isArray, G as either, H as allPass, I as isEmpty, L as isFiniteNumber, M as isUndefined, N as isWeakMap, O as isSet, P as isWeakSet, R as isInteger, S as isNull, T as isPrimitive, U as anyPass, V as isObject, W as both, _ as isLength, a as isBuffer, b as isNode, c as isEqual, d as isFile, f as isFunction, g as isJSONValue, h as isJSONObject, i as isBrowser, j as isTypedArray, k as isString, l as isEqualWith, m as isJSONArray, n as isBlob, o as isDate, p as isJSON, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isMap, w as isPlainObject, x as isNotNil, y as isNil, z as isNaN } from "./index-g2aw5tc_.mjs";
10
- import { Mutex, Semaphore, delay, timeout, withTimeout } from "./promise/index.mjs";
11
- import { camelCase, capitalize, constantCase, deburr, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "./string/index.mjs";
12
- import { a as Err, i as match, n as Pattern, o as Ok, r as isMatching, s as P, t as NonExhaustiveError } from "./index-DtnKhaAD.mjs";
13
- export { AbortError, type DebounceOptions, type DebouncedFunction, type Err, type MemoizeCache, Mutex, NonExhaustiveError, type Ok, P, Pattern, type Result, Semaphore, type ThrottleOptions, type ThrottledFunction, TimeoutError, adjust, after, allPass, anyPass, ary, ascend, assert, asyncNoop, at, attempt, attemptAsync, before, both, call, callAsync, camelCase, capitalize, chunk, clamp, clone, cloneDeep, cloneDeepWith, compact, constantCase, countBy, curry, curryRight, debounce, deburr, delay, descend, difference, differenceBy, differenceWith, drop, dropRepeats, dropRight, dropRightWhile, dropWhile, either, err, escape, escapeRegExp, evolve, fill, filterAsync, findKey, flatMap, flatMapAsync, flatMapDeep, flatten, flattenDeep, flattenObject, flow, flowAsync, flowRight, forEachAsync, forEachRight, groupBy, head, identity, ifElse, inRange, initial, intersection, intersectionBy, intersectionWith, invariant, invert, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isErr, isError, isFile, isFiniteNumber, isFunction, isInteger, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isMatching, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isOk, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSubset, isSubsetWith, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet, kebabCase, keyBy, last, limitAsync, lowerCase, lowerFirst, mapAsync, mapKeys, mapValues, match, maxBy, mean, meanBy, median, medianBy, memoize, merge, mergeWith, minBy, negate, noop, ok, omit, omitBy, once, orderBy, pad, partial, partialRight, partition, pascalCase, pick, pickBy, pull, pullAt, random, randomInt, range, rangeRight, reduceAsync, reduceWhile, remove, rest, retry, reverseString, round, sample, sampleSize, scan, shuffle, snakeCase, sortBy, sortWith, spread, startCase, stringify, sum, sumBy, tail, take, takeRight, takeRightWhile, takeWhile, tap, throttle, timeout, toArray, toBoolean, toCamelCaseKeys, toError, toFilled, toFinite, toInteger, toMerged, toNumber, toSnakeCaseKeys, toString, todo, trim, trimEnd, trimStart, unary, unescape, unfold, unimplemented, union, unionBy, unionWith, uniq, uniqBy, uniqWith, unless, unreachable, unwrap, unzip, unzipWith, upperCase, upperFirst, when, windowed, withTimeout, without, words, xor, xorBy, xorWith, zip, zipObject, zipWith };
6
+ import { A as unless, C as retry, D as flowAsync, E as unary, M as call, N as callAsync, O as tap, S as rest, T as throttle, _ as negate, a as ThrottledFunction, b as partial, c as asyncNoop, d as curryRight, f as debounce, g as memoize, h as identity, i as ThrottleOptions, j as when, k as ifElse, l as before, m as flowRight, n as DebouncedFunction, o as after, p as flow, r as MemoizeCache, s as ary, t as DebounceOptions, u as curry, v as noop, w as spread, x as partialRight, y as once } from "./index-DlZyDxI_.mjs";
7
+ import { clamp, inRange, mean, meanBy, median, medianBy, percentile, random, randomInt, range, rangeRight, round, sum, sumBy } from "./math/index.mjs";
8
+ import { A as evolve, C as sortKeys, D as toMerged, E as toKebabCaseKeys, O as toPascalCaseKeys, S as pickBy, T as toConstantCaseKeys, _ as merge, a as ToSnakeCaseKeys, b as omitBy, c as cloneDeepWith, d as flattenObject, f as invert, g as mapValuesAsync, h as mapValues, i as ToPascalCaseKeys, k as toSnakeCaseKeys, l as deepFreeze, m as mapKeysAsync, n as ToConstantCaseKeys, o as clone, p as mapKeys, r as ToKebabCaseKeys, s as cloneDeep, t as ToCamelCaseKeys, u as findKey, v as mergeWith, w as toCamelCaseKeys, x as pick, y as omit } from "./index-DTrYN2UY.mjs";
9
+ import { A as isString, B as isNaN, C as isNull, D as isPromise, E as isPrimitive, F as isWeakSet, G as both, H as isObject, I as isArray, K as either, L as isEmpty, M as isTypedArray, N as isUndefined, O as isRegExp, P as isWeakMap, R as isFiniteNumber, S as isNotNil, T as isPlainObject, U as allPass, V as isNotEmpty, W as anyPass, _ as isJSONValue, a as isBuffer, b as isNil, c as isEqual, d as isFile, f as isFunction, g as isJSONObject, h as isJSONArray, i as isBrowser, j as isSymbol, k as isSet, l as isEqualWith, m as isJSON, n as isBlob, o as isDate, p as isIterable, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isLength, w as isNumber, x as isNode, y as isMap, z as isInteger } from "./index-D7DGVrkN.mjs";
10
+ import { Mutex, Semaphore, allKeyed, delay, limitAsync, timeout, withTimeout } from "./promise/index.mjs";
11
+ import { camelCase, capitalize, constantCase, deburr, dedent, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "./string/index.mjs";
12
+ import { a as Err, i as match, n as Pattern, o as Ok, r as isMatching, s as P, t as NonExhaustiveError } from "./index-DcVpX2Bb.mjs";
13
+ export { AbortError, type DebounceOptions, type DebouncedFunction, type Err, type MemoizeCache, Mutex, NonExhaustiveError, type Ok, P, Pattern, type Result, Semaphore, type ThrottleOptions, type ThrottledFunction, TimeoutError, type ToCamelCaseKeys, type ToConstantCaseKeys, type ToKebabCaseKeys, type ToPascalCaseKeys, type ToSnakeCaseKeys, adjust, after, allKeyed, allPass, anyPass, ary, ascend, assert, asyncNoop, at, attempt, attemptAsync, before, both, call, callAsync, camelCase, capitalize, cartesianProduct, chunk, chunkBy, clamp, clone, cloneDeep, cloneDeepWith, combinations, compact, constantCase, countBy, curry, curryRight, debounce, deburr, dedent, deepFreeze, delay, descend, difference, differenceBy, differenceWith, drop, dropRepeats, dropRight, dropRightWhile, dropWhile, either, err, escape, escapeRegExp, evolve, fill, filterAsync, findKey, flatMap, flatMapAsync, flatMapDeep, flatten, flattenDeep, flattenObject, flow, flowAsync, flowRight, forEachAsync, forEachRight, groupBy, head, identity, ifElse, inRange, initial, intersection, intersectionBy, intersectionWith, invariant, invert, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isErr, isError, isFile, isFiniteNumber, isFunction, isInteger, isIterable, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isMatching, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isOk, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSubset, isSubsetWith, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet, kebabCase, keyBy, last, limitAsync, lowerCase, lowerFirst, mapAsync, mapKeys, mapKeysAsync, mapValues, mapValuesAsync, match, maxBy, mean, meanBy, median, medianBy, memoize, merge, mergeWith, minBy, negate, noop, ok, omit, omitBy, once, orderBy, pad, partial, partialRight, partition, pascalCase, percentile, pick, pickBy, pull, pullAt, random, randomInt, range, rangeRight, reduceAsync, reduceWhile, remove, rest, retry, reverseString, round, sample, sampleSize, scan, shuffle, snakeCase, sortBy, sortKeys, sortWith, spread, startCase, stringify, sum, sumBy, tail, take, takeRight, takeRightWhile, takeWhile, tap, throttle, timeout, toArray, toBoolean, toCamelCaseKeys, toConstantCaseKeys, toError, toFilled, toFinite, toInteger, toKebabCaseKeys, toMerged, toNumber, toPascalCaseKeys, toSnakeCaseKeys, toString, todo, trim, trimEnd, trimStart, unary, unescape, unfold, unimplemented, union, unionBy, unionWith, uniq, uniqBy, uniqWith, unless, unreachable, unwrap, unzip, unzipWith, upperCase, upperFirst, when, windowed, withTimeout, without, words, xor, xorBy, xorWith, zip, zipObject, zipWith };
package/dist/index.mjs CHANGED
@@ -1,12 +1,12 @@
1
- import { $ as unionWith, A as last, B as remove, C as initial, D as isSubset, E as intersectionWith, F as orderBy, G as tail, H as sampleSize, I as partition, J as takeRightWhile, K as take, L as pull, M as mapAsync, N as maxBy, O as isSubsetWith, P as minBy, Q as unionBy, R as pullAt, S as head, T as intersectionBy, U as shuffle, V as sample, W as sortBy, X as toFilled, Y as takeWhile, Z as union, _ as flatten, _t as scan, a as difference, at as windowed, b as forEachRight, bt as adjust, c as drop, ct as xorBy, d as dropWhile, dt as zipObject, et as uniq, f as fill, ft as zipWith, g as flatMapDeep, gt as sortWith, h as flatMapAsync, ht as descend, i as countBy, it as unzipWith, j as limitAsync, k as keyBy, l as dropRight, lt as xorWith, m as flatMap, mt as ascend, n as chunk, nt as uniqWith, o as differenceBy, ot as without, p as filterAsync, pt as unfold, q as takeRight, r as compact, rt as unzip, s as differenceWith, st as xor, t as at, tt as uniqBy, u as dropRightWhile, ut as zip, v as flattenDeep, vt as reduceWhile, w as intersection, x as groupBy, y as forEachAsync, yt as dropRepeats, z as reduceAsync } from "./array-C8MqjyiP.mjs";
1
+ import { $ as union, A as isSubset, B as pullAt, C as forEachRight, D as intersection, E as initial, F as maxBy, G as shuffle, H as remove, I as minBy, J as take, K as sortBy, L as orderBy, M as keyBy, N as last, O as intersectionBy, P as mapAsync, Q as toFilled, R as partition, S as forEachAsync, St as adjust, T as head, U as sample, V as reduceAsync, W as sampleSize, X as takeRightWhile, Y as takeRight, Z as takeWhile, _ as flatMap, _t as descend, a as combinations, at as unzip, b as flatten, bt as reduceWhile, c as difference, ct as without, d as drop, dt as xorWith, et as unionBy, f as dropRight, ft as zip, g as filterAsync, gt as ascend, h as fill, ht as unfold, i as chunkBy, it as uniqWith, j as isSubsetWith, k as intersectionWith, l as differenceBy, lt as xor, m as dropWhile, mt as zipWith, n as cartesianProduct, nt as uniq, o as compact, ot as unzipWith, p as dropRightWhile, pt as zipObject, q as tail, r as chunk, rt as uniqBy, s as countBy, st as windowed, t as at, tt as unionWith, u as differenceWith, ut as xorBy, v as flatMapAsync, vt as sortWith, w as groupBy, x as flattenDeep, xt as dropRepeats, y as flatMapDeep, yt as scan, z as pull } from "./array-glQHknc3.mjs";
2
2
  import { AbortError, TimeoutError } from "./error/index.mjs";
3
- import { C as tap, D as call, E as when, O as callAsync, S as flowAsync, T as unless, _ as rest, a as curry, b as throttle, c as flow, d as memoize, f as negate, g as partialRight, h as partial, i as before, l as flowRight, m as once, n as ary, o as curryRight, p as noop, r as asyncNoop, s as debounce, t as after, u as identity, v as retry, w as ifElse, x as unary, y as spread } from "./function-2-6QB4m7.mjs";
4
- import { clamp, inRange, mean, meanBy, median, medianBy, random, randomInt, range, rangeRight, round, sum, sumBy } from "./math/index.mjs";
5
- import { _ as toSnakeCaseKeys, a as flattenObject, c as mapValues, d as omit, f as omitBy, g as toMerged, h as toCamelCaseKeys, i as findKey, l as merge, m as pickBy, n as cloneDeep, o as invert, p as pick, r as cloneDeepWith, s as mapKeys, t as clone, u as mergeWith, v as evolve } from "./object-BHnp9Sr9.mjs";
6
- import { A as isSymbol, B as isNotEmpty, C as isNumber, D as isRegExp, E as isPromise, F as isArray, G as either, H as allPass, I as isEmpty, L as isFiniteNumber, M as isUndefined, N as isWeakMap, O as isSet, P as isWeakSet, R as isInteger, S as isNull, T as isPrimitive, U as anyPass, V as isObject, W as both, _ as isLength, a as isBuffer, b as isNode, c as isEqual, d as isFile, f as isFunction, g as isJSONValue, h as isJSONObject, i as isBrowser, j as isTypedArray, k as isString, l as isEqualWith, m as isJSONArray, n as isBlob, o as isDate, p as isJSON, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isMap, w as isPlainObject, x as isNotNil, y as isNil, z as isNaN } from "./predicate-DtTBffBT.mjs";
7
- import { a as toFinite, c as toString, i as toError, n as toArray, o as toInteger, r as toBoolean, s as toNumber, t as stringify } from "./conversion-ByBXBR5i.mjs";
8
- import { Mutex, Semaphore, delay, timeout, withTimeout } from "./promise/index.mjs";
9
- import { camelCase, capitalize, constantCase, deburr, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "./string/index.mjs";
10
- import { a as todo, c as err, d as ok, f as unwrap, i as unimplemented, l as isErr, n as invariant, o as attempt, r as unreachable, s as attemptAsync, t as assert, u as isOk } from "./control-Dg2fwHB7.mjs";
11
- import { a as P, i as match, n as Pattern, r as isMatching, t as NonExhaustiveError } from "./match-CG_v2C4Q.mjs";
12
- export { AbortError, Mutex, NonExhaustiveError, P, Pattern, Semaphore, TimeoutError, adjust, after, allPass, anyPass, ary, ascend, assert, asyncNoop, at, attempt, attemptAsync, before, both, call, callAsync, camelCase, capitalize, chunk, clamp, clone, cloneDeep, cloneDeepWith, compact, constantCase, countBy, curry, curryRight, debounce, deburr, delay, descend, difference, differenceBy, differenceWith, drop, dropRepeats, dropRight, dropRightWhile, dropWhile, either, err, escape, escapeRegExp, evolve, fill, filterAsync, findKey, flatMap, flatMapAsync, flatMapDeep, flatten, flattenDeep, flattenObject, flow, flowAsync, flowRight, forEachAsync, forEachRight, groupBy, head, identity, ifElse, inRange, initial, intersection, intersectionBy, intersectionWith, invariant, invert, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isErr, isError, isFile, isFiniteNumber, isFunction, isInteger, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isMatching, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isOk, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSubset, isSubsetWith, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet, kebabCase, keyBy, last, limitAsync, lowerCase, lowerFirst, mapAsync, mapKeys, mapValues, match, maxBy, mean, meanBy, median, medianBy, memoize, merge, mergeWith, minBy, negate, noop, ok, omit, omitBy, once, orderBy, pad, partial, partialRight, partition, pascalCase, pick, pickBy, pull, pullAt, random, randomInt, range, rangeRight, reduceAsync, reduceWhile, remove, rest, retry, reverseString, round, sample, sampleSize, scan, shuffle, snakeCase, sortBy, sortWith, spread, startCase, stringify, sum, sumBy, tail, take, takeRight, takeRightWhile, takeWhile, tap, throttle, timeout, toArray, toBoolean, toCamelCaseKeys, toError, toFilled, toFinite, toInteger, toMerged, toNumber, toSnakeCaseKeys, toString, todo, trim, trimEnd, trimStart, unary, unescape, unfold, unimplemented, union, unionBy, unionWith, uniq, uniqBy, uniqWith, unless, unreachable, unwrap, unzip, unzipWith, upperCase, upperFirst, when, windowed, withTimeout, without, words, xor, xorBy, xorWith, zip, zipObject, zipWith };
3
+ import { C as tap, D as call, E as when, O as callAsync, S as flowAsync, T as unless, _ as rest, a as curry, b as throttle, c as flow, d as memoize, f as negate, g as partialRight, h as partial, i as before, l as flowRight, m as once, n as ary, o as curryRight, p as noop, r as asyncNoop, s as debounce, t as after, u as identity, v as retry, w as ifElse, x as unary, y as spread } from "./function-Brosl7-Y.mjs";
4
+ import { clamp, inRange, mean, meanBy, median, medianBy, percentile, random, randomInt, range, rangeRight, round, sum, sumBy } from "./math/index.mjs";
5
+ import { C as toPascalCaseKeys, S as toMerged, T as evolve, _ as pickBy, a as findKey, b as toConstantCaseKeys, c as mapKeys, d as mapValuesAsync, f as merge, g as pick, h as omitBy, i as deepFreeze, l as mapKeysAsync, m as omit, n as cloneDeep, o as flattenObject, p as mergeWith, r as cloneDeepWith, s as invert, t as clone, u as mapValues, v as sortKeys, w as toSnakeCaseKeys, x as toKebabCaseKeys, y as toCamelCaseKeys } from "./object-CILtZbTT.mjs";
6
+ import { A as isString, B as isNaN, C as isNull, D as isPromise, E as isPrimitive, F as isWeakSet, G as both, H as isObject, I as isArray, K as either, L as isEmpty, M as isTypedArray, N as isUndefined, O as isRegExp, P as isWeakMap, R as isFiniteNumber, S as isNotNil, T as isPlainObject, U as allPass, V as isNotEmpty, W as anyPass, _ as isJSONValue, a as isBuffer, b as isNil, c as isEqual, d as isFile, f as isFunction, g as isJSONObject, h as isJSONArray, i as isBrowser, j as isSymbol, k as isSet, l as isEqualWith, m as isJSON, n as isBlob, o as isDate, p as isIterable, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isLength, w as isNumber, x as isNode, y as isMap, z as isInteger } from "./predicate-CleUejOb.mjs";
7
+ import { a as toFinite, c as toString, i as toError, n as toArray, o as toInteger, r as toBoolean, s as toNumber, t as stringify } from "./conversion-BB912-15.mjs";
8
+ import { Mutex, Semaphore, allKeyed, delay, limitAsync, timeout, withTimeout } from "./promise/index.mjs";
9
+ import { camelCase, capitalize, constantCase, deburr, dedent, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "./string/index.mjs";
10
+ import { a as todo, c as err, d as ok, f as unwrap, i as unimplemented, l as isErr, n as invariant, o as attempt, r as unreachable, s as attemptAsync, t as assert, u as isOk } from "./control-DCdm8IH6.mjs";
11
+ import { a as P, i as match, n as Pattern, r as isMatching, t as NonExhaustiveError } from "./match-fBetfaIa.mjs";
12
+ export { AbortError, Mutex, NonExhaustiveError, P, Pattern, Semaphore, TimeoutError, adjust, after, allKeyed, allPass, anyPass, ary, ascend, assert, asyncNoop, at, attempt, attemptAsync, before, both, call, callAsync, camelCase, capitalize, cartesianProduct, chunk, chunkBy, clamp, clone, cloneDeep, cloneDeepWith, combinations, compact, constantCase, countBy, curry, curryRight, debounce, deburr, dedent, deepFreeze, delay, descend, difference, differenceBy, differenceWith, drop, dropRepeats, dropRight, dropRightWhile, dropWhile, either, err, escape, escapeRegExp, evolve, fill, filterAsync, findKey, flatMap, flatMapAsync, flatMapDeep, flatten, flattenDeep, flattenObject, flow, flowAsync, flowRight, forEachAsync, forEachRight, groupBy, head, identity, ifElse, inRange, initial, intersection, intersectionBy, intersectionWith, invariant, invert, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isErr, isError, isFile, isFiniteNumber, isFunction, isInteger, isIterable, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isMatching, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isOk, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSubset, isSubsetWith, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet, kebabCase, keyBy, last, limitAsync, lowerCase, lowerFirst, mapAsync, mapKeys, mapKeysAsync, mapValues, mapValuesAsync, match, maxBy, mean, meanBy, median, medianBy, memoize, merge, mergeWith, minBy, negate, noop, ok, omit, omitBy, once, orderBy, pad, partial, partialRight, partition, pascalCase, percentile, pick, pickBy, pull, pullAt, random, randomInt, range, rangeRight, reduceAsync, reduceWhile, remove, rest, retry, reverseString, round, sample, sampleSize, scan, shuffle, snakeCase, sortBy, sortKeys, sortWith, spread, startCase, stringify, sum, sumBy, tail, take, takeRight, takeRightWhile, takeWhile, tap, throttle, timeout, toArray, toBoolean, toCamelCaseKeys, toConstantCaseKeys, toError, toFilled, toFinite, toInteger, toKebabCaseKeys, toMerged, toNumber, toPascalCaseKeys, toSnakeCaseKeys, toString, todo, trim, trimEnd, trimStart, unary, unescape, unfold, unimplemented, union, unionBy, unionWith, uniq, uniqBy, uniqWith, unless, unreachable, unwrap, unzip, unzipWith, upperCase, upperFirst, when, windowed, withTimeout, without, words, xor, xorBy, xorWith, zip, zipObject, zipWith };
@@ -1,2 +1,2 @@
1
- import { a as Err, i as match, n as Pattern, o as Ok, r as isMatching, s as P, t as NonExhaustiveError } from "../index-DtnKhaAD.mjs";
2
- export { Err, NonExhaustiveError, Ok, P, Pattern, isMatching, match };
1
+ import { a as Err, i as match, n as Pattern, o as Ok, r as isMatching, s as P, t as NonExhaustiveError } from "../index-DcVpX2Bb.mjs";
2
+ export { type Err, NonExhaustiveError, type Ok, P, Pattern, isMatching, match };
@@ -1,2 +1,2 @@
1
- import { a as P, i as match, n as Pattern, r as isMatching, t as NonExhaustiveError } from "../match-CG_v2C4Q.mjs";
1
+ import { a as P, i as match, n as Pattern, r as isMatching, t as NonExhaustiveError } from "../match-fBetfaIa.mjs";
2
2
  export { NonExhaustiveError, P, Pattern, isMatching, match };
@@ -0,0 +1,49 @@
1
+ import { NonExhaustiveError, P, Pattern, isMatching, match, match as match$1 } from "ts-pattern";
2
+ //#region src/match/match.ts
3
+ /**
4
+ * Extends ts-pattern's `P` namespace with `P.ok()` and `P.err()` — pattern
5
+ * factories for matching a `Result` and its contained value or error.
6
+ *
7
+ * Mirrors Rust's `Ok(value)` / `Err(error)` match arms, but uses the
8
+ * namespace-method form (`P.ok()` / `P.err()`) so it doesn't collide with
9
+ * the lowercase `ok()` / `err()` constructors from `massaman/control`.
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * import { match, P, attempt } from 'massaman'
14
+ *
15
+ * match(attempt(() => JSON.parse(raw)))
16
+ * .with(P.ok(), ({ value }) => use(value))
17
+ * .with(P.err(), ({ error }) => log(error))
18
+ * .exhaustive()
19
+ * ```
20
+ */
21
+ function okPattern(...patterns) {
22
+ return match(patterns).with([], () => ({ ok: true })).otherwise(([pattern]) => ({
23
+ ok: true,
24
+ value: pattern
25
+ }));
26
+ }
27
+ function errPattern(...patterns) {
28
+ return match(patterns).with([], () => ({ ok: false })).otherwise(([pattern]) => ({
29
+ ok: false,
30
+ error: pattern
31
+ }));
32
+ }
33
+ /**
34
+ * Extended ts-pattern `P` namespace. Carries everything ts-pattern exports
35
+ * (`P.string`, `P.number`, `P.array`, `P.when`, …) plus `P.ok()` / `P.err()`
36
+ * for matching `Result` values and their contents.
37
+ *
38
+ * For the `P.Pattern<T>` type shorthand, import `Pattern` standalone from
39
+ * `massaman/match` — it's the form ts-pattern's own docs recommend.
40
+ */
41
+ const P$1 = {
42
+ ...P,
43
+ ok: okPattern,
44
+ err: errPattern
45
+ };
46
+ //#endregion
47
+ export { P$1 as a, match$1 as i, Pattern as n, isMatching as r, NonExhaustiveError as t };
48
+
49
+ //# sourceMappingURL=match-fBetfaIa.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"match-fBetfaIa.mjs","names":["matchValue","P","TsP"],"sources":["../src/match/match.ts"],"sourcesContent":["/**\n * Extends ts-pattern's `P` namespace with `P.ok()` and `P.err()` — pattern\n * factories for matching a `Result` and its contained value or error.\n *\n * Mirrors Rust's `Ok(value)` / `Err(error)` match arms, but uses the\n * namespace-method form (`P.ok()` / `P.err()`) so it doesn't collide with\n * the lowercase `ok()` / `err()` constructors from `massaman/control`.\n *\n * @example\n * ```ts\n * import { match, P, attempt } from 'massaman'\n *\n * match(attempt(() => JSON.parse(raw)))\n * .with(P.ok(), ({ value }) => use(value))\n * .with(P.err(), ({ error }) => log(error))\n * .exhaustive()\n * ```\n */\n\nimport { match as matchValue, P as TsP } from 'ts-pattern'\n\nimport type { Err as ErrType, Ok as OkType } from '../control/types.js'\n\nfunction okPattern(): { ok: true }\nfunction okPattern<const pattern extends TsP.Pattern<unknown>>(\n pattern: pattern\n): { ok: true; value: pattern }\nfunction okPattern(\n ...patterns: readonly [] | readonly [TsP.Pattern<unknown>]\n): { ok: true } | { ok: true; value: TsP.Pattern<unknown> } {\n return matchValue(patterns)\n .with([], () => ({ ok: true as const }))\n .otherwise(([pattern]) => ({ ok: true as const, value: pattern }))\n}\n\nfunction errPattern(): { ok: false }\nfunction errPattern<const pattern extends TsP.Pattern<unknown>>(\n pattern: pattern\n): { ok: false; error: pattern }\nfunction errPattern(\n ...patterns: readonly [] | readonly [TsP.Pattern<unknown>]\n): { ok: false } | { ok: false; error: TsP.Pattern<unknown> } {\n return matchValue(patterns)\n .with([], () => ({ ok: false as const }))\n .otherwise(([pattern]) => ({ ok: false as const, error: pattern }))\n}\n\n/**\n * Extended ts-pattern `P` namespace. Carries everything ts-pattern exports\n * (`P.string`, `P.number`, `P.array`, `P.when`, …) plus `P.ok()` / `P.err()`\n * for matching `Result` values and their contents.\n *\n * For the `P.Pattern<T>` type shorthand, import `Pattern` standalone from\n * `massaman/match` — it's the form ts-pattern's own docs recommend.\n */\nexport const P: typeof TsP & { ok: typeof okPattern; err: typeof errPattern } = {\n ...TsP,\n ok: okPattern,\n err: errPattern,\n}\n\n/**\n * The `Ok` variant of a `Result<T>`. Re-exported here so the value-side\n * patterns and the type-side `Ok<T>` live in one module — any consumer\n * import gets both type and value namespaces without cross-module merge\n * issues (TS2300).\n */\nexport type Ok<T> = OkType<T>\n\n/**\n * The `Err` variant of a `Result<T>`. See {@link Ok} for the co-location note.\n */\nexport type Err = ErrType\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AA2BA,SAAS,UACP,GAAG,UACuD;CAC1D,OAAOA,MAAW,QAAQ,CAAC,CACxB,KAAK,CAAC,UAAU,EAAE,IAAI,KAAc,EAAE,CAAC,CACvC,WAAW,CAAC,cAAc;EAAE,IAAI;EAAe,OAAO;CAAQ,EAAE;AACrE;AAMA,SAAS,WACP,GAAG,UACyD;CAC5D,OAAOA,MAAW,QAAQ,CAAC,CACxB,KAAK,CAAC,UAAU,EAAE,IAAI,MAAe,EAAE,CAAC,CACxC,WAAW,CAAC,cAAc;EAAE,IAAI;EAAgB,OAAO;CAAQ,EAAE;AACtE;;;;;;;;;AAUA,MAAaC,MAAmE;CAC9E,GAAGC;CACH,IAAI;CACJ,KAAK;AACP"}
@@ -1,2 +1,2 @@
1
- import { clamp, inRange, mean, meanBy, median, medianBy, random, randomInt, range, rangeRight, round, sum, sumBy } from "es-toolkit/math";
2
- export { clamp, inRange, mean, meanBy, median, medianBy, random, randomInt, range, rangeRight, round, sum, sumBy };
1
+ import { clamp, inRange, mean, meanBy, median, medianBy, percentile, random, randomInt, range, rangeRight, round, sum, sumBy } from "es-toolkit/math";
2
+ export { clamp, inRange, mean, meanBy, median, medianBy, percentile, random, randomInt, range, rangeRight, round, sum, sumBy };
@@ -1,2 +1,2 @@
1
- import { clamp, inRange, mean, meanBy, median, medianBy, random, randomInt, range, rangeRight, round, sum, sumBy } from "es-toolkit/math";
2
- export { clamp, inRange, mean, meanBy, median, medianBy, random, randomInt, range, rangeRight, round, sum, sumBy };
1
+ import { clamp, inRange, mean, meanBy, median, medianBy, percentile, random, randomInt, range, rangeRight, round, sum, sumBy } from "es-toolkit/math";
2
+ export { clamp, inRange, mean, meanBy, median, medianBy, percentile, random, randomInt, range, rangeRight, round, sum, sumBy };
@@ -1,2 +1,2 @@
1
- import { _ as toSnakeCaseKeys, a as flattenObject, c as mapValues, d as omit, f as omitBy, g as toMerged, h as toCamelCaseKeys, i as findKey, l as merge, m as pickBy, n as cloneDeep, o as invert, p as pick, r as cloneDeepWith, s as mapKeys, t as clone, u as mergeWith, v as evolve } from "../index-keGHab-v.mjs";
2
- export { clone, cloneDeep, cloneDeepWith, evolve, findKey, flattenObject, invert, mapKeys, mapValues, merge, mergeWith, omit, omitBy, pick, pickBy, toCamelCaseKeys, toMerged, toSnakeCaseKeys };
1
+ import { A as evolve, C as sortKeys, D as toMerged, E as toKebabCaseKeys, O as toPascalCaseKeys, S as pickBy, T as toConstantCaseKeys, _ as merge, a as ToSnakeCaseKeys, b as omitBy, c as cloneDeepWith, d as flattenObject, f as invert, g as mapValuesAsync, h as mapValues, i as ToPascalCaseKeys, k as toSnakeCaseKeys, l as deepFreeze, m as mapKeysAsync, n as ToConstantCaseKeys, o as clone, p as mapKeys, r as ToKebabCaseKeys, s as cloneDeep, t as ToCamelCaseKeys, u as findKey, v as mergeWith, w as toCamelCaseKeys, x as pick, y as omit } from "../index-DTrYN2UY.mjs";
2
+ export { type ToCamelCaseKeys, type ToConstantCaseKeys, type ToKebabCaseKeys, type ToPascalCaseKeys, type ToSnakeCaseKeys, clone, cloneDeep, cloneDeepWith, deepFreeze, evolve, findKey, flattenObject, invert, mapKeys, mapKeysAsync, mapValues, mapValuesAsync, merge, mergeWith, omit, omitBy, pick, pickBy, sortKeys, toCamelCaseKeys, toConstantCaseKeys, toKebabCaseKeys, toMerged, toPascalCaseKeys, toSnakeCaseKeys };
@@ -1,2 +1,2 @@
1
- import { _ as toSnakeCaseKeys, a as flattenObject, c as mapValues, d as omit, f as omitBy, g as toMerged, h as toCamelCaseKeys, i as findKey, l as merge, m as pickBy, n as cloneDeep, o as invert, p as pick, r as cloneDeepWith, s as mapKeys, t as clone, u as mergeWith, v as evolve } from "../object-BHnp9Sr9.mjs";
2
- export { clone, cloneDeep, cloneDeepWith, evolve, findKey, flattenObject, invert, mapKeys, mapValues, merge, mergeWith, omit, omitBy, pick, pickBy, toCamelCaseKeys, toMerged, toSnakeCaseKeys };
1
+ import { C as toPascalCaseKeys, S as toMerged, T as evolve, _ as pickBy, a as findKey, b as toConstantCaseKeys, c as mapKeys, d as mapValuesAsync, f as merge, g as pick, h as omitBy, i as deepFreeze, l as mapKeysAsync, m as omit, n as cloneDeep, o as flattenObject, p as mergeWith, r as cloneDeepWith, s as invert, t as clone, u as mapValues, v as sortKeys, w as toSnakeCaseKeys, x as toKebabCaseKeys, y as toCamelCaseKeys } from "../object-CILtZbTT.mjs";
2
+ export { clone, cloneDeep, cloneDeepWith, deepFreeze, evolve, findKey, flattenObject, invert, mapKeys, mapKeysAsync, mapValues, mapValuesAsync, merge, mergeWith, omit, omitBy, pick, pickBy, sortKeys, toCamelCaseKeys, toConstantCaseKeys, toKebabCaseKeys, toMerged, toPascalCaseKeys, toSnakeCaseKeys };
@@ -0,0 +1,27 @@
1
+ import { clone, cloneDeep, cloneDeepWith, deepFreeze, findKey, flattenObject, invert, mapKeys, mapKeysAsync, mapValues, mapValuesAsync, merge, mergeWith, omit, omitBy, pick, pickBy, sortKeys, toCamelCaseKeys, toConstantCaseKeys, toKebabCaseKeys, toMerged, toPascalCaseKeys, toSnakeCaseKeys } from "es-toolkit/object";
2
+ //#region src/object/evolve.ts
3
+ /**
4
+ * Applies a spec of transformation functions to matching keys of an object,
5
+ * returning a new object. Keys not in the spec are copied as-is.
6
+ *
7
+ * @example
8
+ * ```ts
9
+ * evolve({ name: ' Alice ', age: 29, role: 'admin' }, {
10
+ * name: (s) => s.trim(),
11
+ * age: (n) => n + 1,
12
+ * })
13
+ * // { name: 'Alice', age: 30, role: 'admin' }
14
+ * ```
15
+ */
16
+ function evolve(obj, spec) {
17
+ const result = { ...obj };
18
+ for (const key of Object.keys(spec)) {
19
+ const transform = spec[key];
20
+ if (transform != null && key in result) result[key] = transform(result[key]);
21
+ }
22
+ return result;
23
+ }
24
+ //#endregion
25
+ export { toPascalCaseKeys as C, toMerged as S, evolve as T, pickBy as _, findKey as a, toConstantCaseKeys as b, mapKeys as c, mapValuesAsync as d, merge as f, pick as g, omitBy as h, deepFreeze as i, mapKeysAsync as l, omit as m, cloneDeep as n, flattenObject as o, mergeWith as p, cloneDeepWith as r, invert as s, clone as t, mapValues as u, sortKeys as v, toSnakeCaseKeys as w, toKebabCaseKeys as x, toCamelCaseKeys as y };
26
+
27
+ //# sourceMappingURL=object-CILtZbTT.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"object-BHnp9Sr9.mjs","names":[],"sources":["../src/object/evolve.ts"],"sourcesContent":["/**\n * Applies a spec of transformation functions to matching keys of an object,\n * returning a new object. Keys not in the spec are copied as-is.\n *\n * @example\n * ```ts\n * evolve({ name: ' Alice ', age: 29, role: 'admin' }, {\n * name: (s) => s.trim(),\n * age: (n) => n + 1,\n * })\n * // { name: 'Alice', age: 30, role: 'admin' }\n * ```\n */\nexport function evolve<T extends Record<string, unknown>>(\n obj: T,\n spec: { [K in keyof T]?: (value: T[K]) => T[K] }\n): T {\n const result = { ...obj }\n for (const key of Object.keys(spec) as Array<keyof T>) {\n // oxlint-disable-next-line security/detect-object-injection -- key sourced from Object.keys(spec), not user input\n const transform = spec[key]\n if (transform != null && key in result) {\n // oxlint-disable-next-line security/detect-object-injection -- key sourced from Object.keys(spec), not user input\n result[key] = transform(result[key])\n }\n }\n return result\n}\n"],"mappings":";;;;;;;;;;;;;;;AAaA,SAAgB,OACd,KACA,MACG;CACH,MAAM,SAAS,EAAE,GAAG,KAAK;CACzB,KAAK,MAAM,OAAO,OAAO,KAAK,KAAK,EAAoB;EAErD,MAAM,YAAY,KAAK;EACvB,IAAI,aAAa,QAAQ,OAAO,QAE9B,OAAO,OAAO,UAAU,OAAO,KAAK;;CAGxC,OAAO"}
1
+ {"version":3,"file":"object-CILtZbTT.mjs","names":[],"sources":["../src/object/evolve.ts"],"sourcesContent":["/**\n * Applies a spec of transformation functions to matching keys of an object,\n * returning a new object. Keys not in the spec are copied as-is.\n *\n * @example\n * ```ts\n * evolve({ name: ' Alice ', age: 29, role: 'admin' }, {\n * name: (s) => s.trim(),\n * age: (n) => n + 1,\n * })\n * // { name: 'Alice', age: 30, role: 'admin' }\n * ```\n */\nexport function evolve<T extends Record<string, unknown>>(\n obj: T,\n spec: { [K in keyof T]?: (value: T[K]) => T[K] }\n): T {\n const result = { ...obj }\n for (const key of Object.keys(spec) as Array<keyof T>) {\n // oxlint-disable-next-line security/detect-object-injection -- key sourced from Object.keys(spec), not user input\n const transform = spec[key]\n if (transform != null && key in result) {\n // oxlint-disable-next-line security/detect-object-injection -- key sourced from Object.keys(spec), not user input\n result[key] = transform(result[key])\n }\n }\n return result\n}\n"],"mappings":";;;;;;;;;;;;;;;AAaA,SAAgB,OACd,KACA,MACG;CACH,MAAM,SAAS,EAAE,GAAG,IAAI;CACxB,KAAK,MAAM,OAAO,OAAO,KAAK,IAAI,GAAqB;EAErD,MAAM,YAAY,KAAK;EACvB,IAAI,aAAa,QAAQ,OAAO,QAE9B,OAAO,OAAO,UAAU,OAAO,IAAI;CAEvC;CACA,OAAO;AACT"}
@@ -1,2 +1,2 @@
1
- import { A as isSymbol, B as isNotEmpty, C as isNumber, D as isRegExp, E as isPromise, F as isArray, G as either, H as allPass, I as isEmpty, L as isFiniteNumber, M as isUndefined, N as isWeakMap, O as isSet, P as isWeakSet, R as isInteger, S as isNull, T as isPrimitive, U as anyPass, V as isObject, W as both, _ as isLength, a as isBuffer, b as isNode, c as isEqual, d as isFile, f as isFunction, g as isJSONValue, h as isJSONObject, i as isBrowser, j as isTypedArray, k as isString, l as isEqualWith, m as isJSONArray, n as isBlob, o as isDate, p as isJSON, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isMap, w as isPlainObject, x as isNotNil, y as isNil, z as isNaN } from "../index-g2aw5tc_.mjs";
2
- export { allPass, anyPass, both, either, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isError, isFile, isFiniteNumber, isFunction, isInteger, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet };
1
+ import { A as isString, B as isNaN, C as isNull, D as isPromise, E as isPrimitive, F as isWeakSet, G as both, H as isObject, I as isArray, K as either, L as isEmpty, M as isTypedArray, N as isUndefined, O as isRegExp, P as isWeakMap, R as isFiniteNumber, S as isNotNil, T as isPlainObject, U as allPass, V as isNotEmpty, W as anyPass, _ as isJSONValue, a as isBuffer, b as isNil, c as isEqual, d as isFile, f as isFunction, g as isJSONObject, h as isJSONArray, i as isBrowser, j as isSymbol, k as isSet, l as isEqualWith, m as isJSON, n as isBlob, o as isDate, p as isIterable, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isLength, w as isNumber, x as isNode, y as isMap, z as isInteger } from "../index-D7DGVrkN.mjs";
2
+ export { allPass, anyPass, both, either, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isError, isFile, isFiniteNumber, isFunction, isInteger, isIterable, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet };
@@ -1,2 +1,2 @@
1
- import { A as isSymbol, B as isNotEmpty, C as isNumber, D as isRegExp, E as isPromise, F as isArray, G as either, H as allPass, I as isEmpty, L as isFiniteNumber, M as isUndefined, N as isWeakMap, O as isSet, P as isWeakSet, R as isInteger, S as isNull, T as isPrimitive, U as anyPass, V as isObject, W as both, _ as isLength, a as isBuffer, b as isNode, c as isEqual, d as isFile, f as isFunction, g as isJSONValue, h as isJSONObject, i as isBrowser, j as isTypedArray, k as isString, l as isEqualWith, m as isJSONArray, n as isBlob, o as isDate, p as isJSON, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isMap, w as isPlainObject, x as isNotNil, y as isNil, z as isNaN } from "../predicate-DtTBffBT.mjs";
2
- export { allPass, anyPass, both, either, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isError, isFile, isFiniteNumber, isFunction, isInteger, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet };
1
+ import { A as isString, B as isNaN, C as isNull, D as isPromise, E as isPrimitive, F as isWeakSet, G as both, H as isObject, I as isArray, K as either, L as isEmpty, M as isTypedArray, N as isUndefined, O as isRegExp, P as isWeakMap, R as isFiniteNumber, S as isNotNil, T as isPlainObject, U as allPass, V as isNotEmpty, W as anyPass, _ as isJSONValue, a as isBuffer, b as isNil, c as isEqual, d as isFile, f as isFunction, g as isJSONObject, h as isJSONArray, i as isBrowser, j as isSymbol, k as isSet, l as isEqualWith, m as isJSON, n as isBlob, o as isDate, p as isIterable, r as isBoolean, s as isEmptyObject, t as isArrayBuffer, u as isError, v as isLength, w as isNumber, x as isNode, y as isMap, z as isInteger } from "../predicate-CleUejOb.mjs";
2
+ export { allPass, anyPass, both, either, isArray, isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmpty, isEmptyObject, isEqual, isEqualWith, isError, isFile, isFiniteNumber, isFunction, isInteger, isIterable, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap, isNaN, isNil, isNode, isNotEmpty, isNotNil, isNull, isNumber, isObject, isPlainObject, isPrimitive, isPromise, isRegExp, isSet, isString, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet };
@@ -1,4 +1,4 @@
1
- import { isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmptyObject, isEqual, isEqualWith, isError as isError$1, isFile, isFunction, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap as isMap$1, isNil as isNil$1, isNode, isNotNil, isNull, isNumber, isPlainObject, isPrimitive as isPrimitive$1, isPromise, isRegExp, isSet as isSet$1, isString as isString$1, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet } from "es-toolkit/predicate";
1
+ import { isArrayBuffer, isBlob, isBoolean, isBrowser, isBuffer, isDate, isEmptyObject, isEqual, isEqualWith, isError as isError$1, isFile, isFunction, isIterable, isJSON, isJSONArray, isJSONObject, isJSONValue, isLength, isMap as isMap$1, isNil as isNil$1, isNode, isNotNil, isNull, isNumber, isPlainObject, isPrimitive as isPrimitive$1, isPromise, isRegExp, isSet as isSet$1, isString as isString$1, isSymbol, isTypedArray, isUndefined, isWeakMap, isWeakSet } from "es-toolkit/predicate";
2
2
  //#region src/predicate/combinators.ts
3
3
  function allPass(predicates) {
4
4
  return (value) => predicates.every((pred) => pred(value));
@@ -111,6 +111,6 @@ function isNaN(value) {
111
111
  return Number.isNaN(value);
112
112
  }
113
113
  //#endregion
114
- export { isSymbol as A, isNotEmpty as B, isNumber as C, isRegExp as D, isPromise as E, isArray as F, either as G, allPass as H, isEmpty as I, isFiniteNumber as L, isUndefined as M, isWeakMap as N, isSet$1 as O, isWeakSet as P, isInteger as R, isNull as S, isPrimitive$1 as T, anyPass as U, isObject as V, both as W, isLength as _, isBuffer as a, isNode as b, isEqual as c, isFile as d, isFunction as f, isJSONValue as g, isJSONObject as h, isBrowser as i, isTypedArray as j, isString$1 as k, isEqualWith as l, isJSONArray as m, isBlob as n, isDate as o, isJSON as p, isBoolean as r, isEmptyObject as s, isArrayBuffer as t, isError$1 as u, isMap$1 as v, isPlainObject as w, isNotNil as x, isNil$1 as y, isNaN as z };
114
+ export { isString$1 as A, isNaN as B, isNull as C, isPromise as D, isPrimitive$1 as E, isWeakSet as F, both as G, isObject as H, isArray as I, either as K, isEmpty as L, isTypedArray as M, isUndefined as N, isRegExp as O, isWeakMap as P, isFiniteNumber as R, isNotNil as S, isPlainObject as T, allPass as U, isNotEmpty as V, anyPass as W, isJSONValue as _, isBuffer as a, isNil$1 as b, isEqual as c, isFile as d, isFunction as f, isJSONObject as g, isJSONArray as h, isBrowser as i, isSymbol as j, isSet$1 as k, isEqualWith as l, isJSON as m, isBlob as n, isDate as o, isIterable as p, isBoolean as r, isEmptyObject as s, isArrayBuffer as t, isError$1 as u, isLength as v, isNumber as w, isNode as x, isMap$1 as y, isInteger as z };
115
115
 
116
- //# sourceMappingURL=predicate-DtTBffBT.mjs.map
116
+ //# sourceMappingURL=predicate-CleUejOb.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"predicate-DtTBffBT.mjs","names":[],"sources":["../src/predicate/combinators.ts","../src/predicate/guards.ts"],"sourcesContent":["import type { DangerouslyAllowAny } from '../types/internal.js'\n\n/**\n * Returns a predicate that checks if a value satisfies ALL predicates.\n *\n * When every input is a type guard, the result narrows to the intersection\n * of every guard's target type. Plain `boolean` predicates contribute nothing\n * to the narrowing (they fall back to no-op).\n *\n * @example\n * ```ts\n * const isPositiveEven = allPass([(n: number) => n > 0, (n: number) => n % 2 === 0])\n * isPositiveEven(4) // true\n *\n * const isNonEmptyString = allPass([isString, isNotEmpty])\n * if (isNonEmptyString(x)) {\n * // x is narrowed to string here\n * }\n * ```\n */\nexport function allPass<T>(predicates: readonly []): (value: T) => true\nexport function allPass<Ps extends ReadonlyArray<(value: DangerouslyAllowAny) => boolean>>(\n predicates: Ps\n): (value: InferInput<Ps>) => value is InferInput<Ps> & UnionToIntersection<Guarded<Ps[number]>>\nexport function allPass(\n predicates: ReadonlyArray<(value: unknown) => boolean>\n): (value: unknown) => boolean {\n return (value: unknown) => predicates.every((pred) => pred(value))\n}\n\n/**\n * Returns a predicate that checks if a value satisfies ANY predicate.\n *\n * When every input is a type guard, the result narrows to the union of every\n * guard's target type (since only one needs to match).\n *\n * @example\n * ```ts\n * const isAdminOrOwner = anyPass([isAdmin, isOwner])\n * isAdminOrOwner(user)\n *\n * const isStringOrNumber = anyPass([isString, isNumber])\n * if (isStringOrNumber(x)) {\n * // x is narrowed to string | number here\n * }\n * ```\n */\nexport function anyPass<T>(predicates: readonly []): (value: T) => false\nexport function anyPass<Ps extends ReadonlyArray<(value: DangerouslyAllowAny) => boolean>>(\n predicates: Ps\n): (value: InferInput<Ps>) => value is InferInput<Ps> & Guarded<Ps[number]>\nexport function anyPass(\n predicates: ReadonlyArray<(value: unknown) => boolean>\n): (value: unknown) => boolean {\n return (value: unknown) => predicates.some((pred) => pred(value))\n}\n\n/**\n * Returns a predicate that checks if a value satisfies both predicates.\n *\n * Binary AND combinator — shorthand for `allPass([f, g])`. When both inputs\n * are type guards, the result narrows to the intersection of their target types.\n *\n * @example\n * ```ts\n * const isPositiveEven = both((n: number) => n > 0, (n: number) => n % 2 === 0)\n * isPositiveEven(4)\n * ```\n */\nexport function both<T, A extends T, B extends T>(\n f: (value: T) => value is A,\n g: (value: T) => value is B\n): (value: T) => value is A & B\nexport function both<T>(f: (value: T) => boolean, g: (value: T) => boolean): (value: T) => boolean\nexport function both<T>(f: (value: T) => boolean, g: (value: T) => boolean): (value: T) => boolean {\n return (value: T) => f(value) && g(value)\n}\n\n/**\n * Returns a predicate that checks if a value satisfies either predicate.\n *\n * Binary OR combinator — shorthand for `anyPass([f, g])`. When both inputs\n * are type guards, the result narrows to the union of their target types.\n *\n * @example\n * ```ts\n * const isNilOrEmpty = either(isNil, (s: string) => s === '')\n * isNilOrEmpty(null)\n * ```\n */\nexport function either<T, A extends T, B extends T>(\n f: (value: T) => value is A,\n g: (value: T) => value is B\n): (value: T) => value is A | B\nexport function either<T>(f: (value: T) => boolean, g: (value: T) => boolean): (value: T) => boolean\nexport function either<T>(\n f: (value: T) => boolean,\n g: (value: T) => boolean\n): (value: T) => boolean {\n return (value: T) => f(value) || g(value)\n}\n\n/**\n * `DangerouslyAllowAny` is required: this conditional needs to match predicate\n * signatures with arbitrary input types. `unknown` would reject them by contravariance.\n */\ntype Guarded<P> = P extends ((value: DangerouslyAllowAny) => value is infer X) ? X : never\n\n/**\n * `infer V` is contravariant here, so multiple predicates with the same input\n * type collapse to that single type.\n */\ntype InferInput<Ps> = Ps extends ReadonlyArray<(value: infer V) => unknown> ? V : never\n\ntype UnionToIntersection<U> = (U extends unknown ? (k: U) => void : never) extends (\n k: infer I\n) => void\n ? I\n : never\n","/**\n * Checks if a value is an array.\n *\n * @example\n * ```ts\n * isArray([1, 2]) // true\n * isArray('hello') // false\n * ```\n */\nexport function isArray(value: unknown): value is unknown[] {\n return Array.isArray(value)\n}\n\n/**\n * Checks if a value is a non-null object.\n *\n * Returns `true` for plain objects, arrays, class instances, etc.\n * Returns `false` for `null`, primitives, and functions.\n *\n * @example\n * ```ts\n * isObject({}) // true\n * isObject(null) // false\n * ```\n */\nexport function isObject(value: unknown): value is object {\n return value !== null && typeof value === 'object'\n}\n\n/**\n * Checks if a value is empty.\n *\n * - Strings: `''`\n * - Arrays: `length === 0`\n * - Maps/Sets: `size === 0`\n * - Objects: no own enumerable keys\n *\n * @example\n * ```ts\n * isEmpty('') // true\n * isEmpty([]) // true\n * isEmpty({}) // true\n * isEmpty(new Map()) // true\n * ```\n */\nexport function isEmpty(value: string | object): boolean {\n if (typeof value === 'string' || Array.isArray(value)) {\n return value.length === 0\n }\n if (value instanceof Map || value instanceof Set) {\n return value.size === 0\n }\n return Object.keys(value).length === 0\n}\n\n/**\n * Checks if a value is not empty. Complement of {@link isEmpty}.\n *\n * @example\n * ```ts\n * isNotEmpty('hello') // true\n * isNotEmpty([]) // false\n * ```\n */\nexport function isNotEmpty(value: string | object): boolean {\n return !isEmpty(value)\n}\n\n/**\n * Checks if a value is a finite number.\n *\n * @example\n * ```ts\n * isFiniteNumber(42) // true\n * isFiniteNumber(Infinity) // false\n * ```\n */\nexport function isFiniteNumber(value: unknown): value is number {\n return Number.isFinite(value)\n}\n\n/**\n * Checks if a value is an integer.\n *\n * @example\n * ```ts\n * isInteger(42) // true\n * isInteger(4.2) // false\n * ```\n */\nexport function isInteger(value: unknown): value is number {\n return Number.isInteger(value)\n}\n\n/**\n * Checks if a value is NaN.\n *\n * @example\n * ```ts\n * isNaN(NaN) // true\n * isNaN(42) // false\n * ```\n */\nexport function isNaN(value: unknown): value is number {\n return Number.isNaN(value)\n}\n"],"mappings":";;AAwBA,SAAgB,QACd,YAC6B;CAC7B,QAAQ,UAAmB,WAAW,OAAO,SAAS,KAAK,MAAM,CAAC;;AAwBpE,SAAgB,QACd,YAC6B;CAC7B,QAAQ,UAAmB,WAAW,MAAM,SAAS,KAAK,MAAM,CAAC;;AAoBnE,SAAgB,KAAQ,GAA0B,GAAiD;CACjG,QAAQ,UAAa,EAAE,MAAM,IAAI,EAAE,MAAM;;AAoB3C,SAAgB,OACd,GACA,GACuB;CACvB,QAAQ,UAAa,EAAE,MAAM,IAAI,EAAE,MAAM;;;;;;;;;;;;;AC1F3C,SAAgB,QAAQ,OAAoC;CAC1D,OAAO,MAAM,QAAQ,MAAM;;;;;;;;;;;;;;AAe7B,SAAgB,SAAS,OAAiC;CACxD,OAAO,UAAU,QAAQ,OAAO,UAAU;;;;;;;;;;;;;;;;;;AAmB5C,SAAgB,QAAQ,OAAiC;CACvD,IAAI,OAAO,UAAU,YAAY,MAAM,QAAQ,MAAM,EACnD,OAAO,MAAM,WAAW;CAE1B,IAAI,iBAAiB,OAAO,iBAAiB,KAC3C,OAAO,MAAM,SAAS;CAExB,OAAO,OAAO,KAAK,MAAM,CAAC,WAAW;;;;;;;;;;;AAYvC,SAAgB,WAAW,OAAiC;CAC1D,OAAO,CAAC,QAAQ,MAAM;;;;;;;;;;;AAYxB,SAAgB,eAAe,OAAiC;CAC9D,OAAO,OAAO,SAAS,MAAM;;;;;;;;;;;AAY/B,SAAgB,UAAU,OAAiC;CACzD,OAAO,OAAO,UAAU,MAAM;;;;;;;;;;;AAYhC,SAAgB,MAAM,OAAiC;CACrD,OAAO,OAAO,MAAM,MAAM"}
1
+ {"version":3,"file":"predicate-CleUejOb.mjs","names":[],"sources":["../src/predicate/combinators.ts","../src/predicate/guards.ts"],"sourcesContent":["import type { DangerouslyAllowAny } from '../types/internal.js'\n\n/**\n * Returns a predicate that checks if a value satisfies ALL predicates.\n *\n * When every input is a type guard, the result narrows to the intersection\n * of every guard's target type. Plain `boolean` predicates contribute nothing\n * to the narrowing (they fall back to no-op).\n *\n * @example\n * ```ts\n * const isPositiveEven = allPass([(n: number) => n > 0, (n: number) => n % 2 === 0])\n * isPositiveEven(4) // true\n *\n * const isNonEmptyString = allPass([isString, isNotEmpty])\n * if (isNonEmptyString(x)) {\n * // x is narrowed to string here\n * }\n * ```\n */\nexport function allPass<T>(predicates: readonly []): (value: T) => true\nexport function allPass<Ps extends ReadonlyArray<(value: DangerouslyAllowAny) => boolean>>(\n predicates: Ps\n): (value: InferInput<Ps>) => value is InferInput<Ps> & UnionToIntersection<Guarded<Ps[number]>>\nexport function allPass(\n predicates: ReadonlyArray<(value: unknown) => boolean>\n): (value: unknown) => boolean {\n return (value: unknown) => predicates.every((pred) => pred(value))\n}\n\n/**\n * Returns a predicate that checks if a value satisfies ANY predicate.\n *\n * When every input is a type guard, the result narrows to the union of every\n * guard's target type (since only one needs to match).\n *\n * @example\n * ```ts\n * const isAdminOrOwner = anyPass([isAdmin, isOwner])\n * isAdminOrOwner(user)\n *\n * const isStringOrNumber = anyPass([isString, isNumber])\n * if (isStringOrNumber(x)) {\n * // x is narrowed to string | number here\n * }\n * ```\n */\nexport function anyPass<T>(predicates: readonly []): (value: T) => false\nexport function anyPass<Ps extends ReadonlyArray<(value: DangerouslyAllowAny) => boolean>>(\n predicates: Ps\n): (value: InferInput<Ps>) => value is InferInput<Ps> & Guarded<Ps[number]>\nexport function anyPass(\n predicates: ReadonlyArray<(value: unknown) => boolean>\n): (value: unknown) => boolean {\n return (value: unknown) => predicates.some((pred) => pred(value))\n}\n\n/**\n * Returns a predicate that checks if a value satisfies both predicates.\n *\n * Binary AND combinator — shorthand for `allPass([f, g])`. When both inputs\n * are type guards, the result narrows to the intersection of their target types.\n *\n * @example\n * ```ts\n * const isPositiveEven = both((n: number) => n > 0, (n: number) => n % 2 === 0)\n * isPositiveEven(4)\n * ```\n */\nexport function both<T, A extends T, B extends T>(\n f: (value: T) => value is A,\n g: (value: T) => value is B\n): (value: T) => value is A & B\nexport function both<T>(f: (value: T) => boolean, g: (value: T) => boolean): (value: T) => boolean\nexport function both<T>(f: (value: T) => boolean, g: (value: T) => boolean): (value: T) => boolean {\n return (value: T) => f(value) && g(value)\n}\n\n/**\n * Returns a predicate that checks if a value satisfies either predicate.\n *\n * Binary OR combinator — shorthand for `anyPass([f, g])`. When both inputs\n * are type guards, the result narrows to the union of their target types.\n *\n * @example\n * ```ts\n * const isNilOrEmpty = either(isNil, (s: string) => s === '')\n * isNilOrEmpty(null)\n * ```\n */\nexport function either<T, A extends T, B extends T>(\n f: (value: T) => value is A,\n g: (value: T) => value is B\n): (value: T) => value is A | B\nexport function either<T>(f: (value: T) => boolean, g: (value: T) => boolean): (value: T) => boolean\nexport function either<T>(\n f: (value: T) => boolean,\n g: (value: T) => boolean\n): (value: T) => boolean {\n return (value: T) => f(value) || g(value)\n}\n\n/**\n * `DangerouslyAllowAny` is required: this conditional needs to match predicate\n * signatures with arbitrary input types. `unknown` would reject them by contravariance.\n */\ntype Guarded<P> = P extends ((value: DangerouslyAllowAny) => value is infer X) ? X : never\n\n/**\n * `infer V` is contravariant here, so multiple predicates with the same input\n * type collapse to that single type.\n */\ntype InferInput<Ps> = Ps extends ReadonlyArray<(value: infer V) => unknown> ? V : never\n\ntype UnionToIntersection<U> = (U extends unknown ? (k: U) => void : never) extends (\n k: infer I\n) => void\n ? I\n : never\n","/**\n * Checks if a value is an array.\n *\n * @example\n * ```ts\n * isArray([1, 2]) // true\n * isArray('hello') // false\n * ```\n */\nexport function isArray(value: unknown): value is unknown[] {\n return Array.isArray(value)\n}\n\n/**\n * Checks if a value is a non-null object.\n *\n * Returns `true` for plain objects, arrays, class instances, etc.\n * Returns `false` for `null`, primitives, and functions.\n *\n * @example\n * ```ts\n * isObject({}) // true\n * isObject(null) // false\n * ```\n */\nexport function isObject(value: unknown): value is object {\n return value !== null && typeof value === 'object'\n}\n\n/**\n * Checks if a value is empty.\n *\n * - Strings: `''`\n * - Arrays: `length === 0`\n * - Maps/Sets: `size === 0`\n * - Objects: no own enumerable keys\n *\n * @example\n * ```ts\n * isEmpty('') // true\n * isEmpty([]) // true\n * isEmpty({}) // true\n * isEmpty(new Map()) // true\n * ```\n */\nexport function isEmpty(value: string | object): boolean {\n if (typeof value === 'string' || Array.isArray(value)) {\n return value.length === 0\n }\n if (value instanceof Map || value instanceof Set) {\n return value.size === 0\n }\n return Object.keys(value).length === 0\n}\n\n/**\n * Checks if a value is not empty. Complement of {@link isEmpty}.\n *\n * @example\n * ```ts\n * isNotEmpty('hello') // true\n * isNotEmpty([]) // false\n * ```\n */\nexport function isNotEmpty(value: string | object): boolean {\n return !isEmpty(value)\n}\n\n/**\n * Checks if a value is a finite number.\n *\n * @example\n * ```ts\n * isFiniteNumber(42) // true\n * isFiniteNumber(Infinity) // false\n * ```\n */\nexport function isFiniteNumber(value: unknown): value is number {\n return Number.isFinite(value)\n}\n\n/**\n * Checks if a value is an integer.\n *\n * @example\n * ```ts\n * isInteger(42) // true\n * isInteger(4.2) // false\n * ```\n */\nexport function isInteger(value: unknown): value is number {\n return Number.isInteger(value)\n}\n\n/**\n * Checks if a value is NaN.\n *\n * @example\n * ```ts\n * isNaN(NaN) // true\n * isNaN(42) // false\n * ```\n */\nexport function isNaN(value: unknown): value is number {\n return Number.isNaN(value)\n}\n"],"mappings":";;AAwBA,SAAgB,QACd,YAC6B;CAC7B,QAAQ,UAAmB,WAAW,OAAO,SAAS,KAAK,KAAK,CAAC;AACnE;AAuBA,SAAgB,QACd,YAC6B;CAC7B,QAAQ,UAAmB,WAAW,MAAM,SAAS,KAAK,KAAK,CAAC;AAClE;AAmBA,SAAgB,KAAQ,GAA0B,GAAiD;CACjG,QAAQ,UAAa,EAAE,KAAK,KAAK,EAAE,KAAK;AAC1C;AAmBA,SAAgB,OACd,GACA,GACuB;CACvB,QAAQ,UAAa,EAAE,KAAK,KAAK,EAAE,KAAK;AAC1C;;;;;;;;;;;;AC3FA,SAAgB,QAAQ,OAAoC;CAC1D,OAAO,MAAM,QAAQ,KAAK;AAC5B;;;;;;;;;;;;;AAcA,SAAgB,SAAS,OAAiC;CACxD,OAAO,UAAU,QAAQ,OAAO,UAAU;AAC5C;;;;;;;;;;;;;;;;;AAkBA,SAAgB,QAAQ,OAAiC;CACvD,IAAI,OAAO,UAAU,YAAY,MAAM,QAAQ,KAAK,GAClD,OAAO,MAAM,WAAW;CAE1B,IAAI,iBAAiB,OAAO,iBAAiB,KAC3C,OAAO,MAAM,SAAS;CAExB,OAAO,OAAO,KAAK,KAAK,CAAC,CAAC,WAAW;AACvC;;;;;;;;;;AAWA,SAAgB,WAAW,OAAiC;CAC1D,OAAO,CAAC,QAAQ,KAAK;AACvB;;;;;;;;;;AAWA,SAAgB,eAAe,OAAiC;CAC9D,OAAO,OAAO,SAAS,KAAK;AAC9B;;;;;;;;;;AAWA,SAAgB,UAAU,OAAiC;CACzD,OAAO,OAAO,UAAU,KAAK;AAC/B;;;;;;;;;;AAWA,SAAgB,MAAM,OAAiC;CACrD,OAAO,OAAO,MAAM,KAAK;AAC3B"}
@@ -1,2 +1,2 @@
1
- import { Mutex, Semaphore, delay, timeout, withTimeout } from "es-toolkit/promise";
2
- export { Mutex, Semaphore, delay, timeout, withTimeout };
1
+ import { Mutex, Semaphore, allKeyed, delay, limitAsync, timeout, withTimeout } from "es-toolkit/promise";
2
+ export { Mutex, Semaphore, allKeyed, delay, limitAsync, timeout, withTimeout };
@@ -1,2 +1,2 @@
1
- import { Mutex, Semaphore, delay, timeout, withTimeout } from "es-toolkit/promise";
2
- export { Mutex, Semaphore, delay, timeout, withTimeout };
1
+ import { Mutex, Semaphore, allKeyed, delay, limitAsync, timeout, withTimeout } from "es-toolkit/promise";
2
+ export { Mutex, Semaphore, allKeyed, delay, limitAsync, timeout, withTimeout };
@@ -1,2 +1,2 @@
1
- import { camelCase, capitalize, constantCase, deburr, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "es-toolkit/string";
2
- export { camelCase, capitalize, constantCase, deburr, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words };
1
+ import { camelCase, capitalize, constantCase, deburr, dedent, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "es-toolkit/string";
2
+ export { camelCase, capitalize, constantCase, deburr, dedent, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words };
@@ -1,2 +1,2 @@
1
- import { camelCase, capitalize, constantCase, deburr, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "es-toolkit/string";
2
- export { camelCase, capitalize, constantCase, deburr, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words };
1
+ import { camelCase, capitalize, constantCase, deburr, dedent, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words } from "es-toolkit/string";
2
+ export { camelCase, capitalize, constantCase, deburr, dedent, escape, escapeRegExp, kebabCase, lowerCase, lowerFirst, pad, pascalCase, reverseString, snakeCase, startCase, trim, trimEnd, trimStart, unescape, upperCase, upperFirst, words };
@@ -39,4 +39,4 @@ interface Err {
39
39
  type Result<T> = Ok<T> | Err;
40
40
  //#endregion
41
41
  export { Ok as n, Result as r, Err as t };
42
- //# sourceMappingURL=types-X6LqLWno.d.mts.map
42
+ //# sourceMappingURL=types-BsimcHZS.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types-BsimcHZS.d.mts","names":[],"sources":["../src/control/types.ts"],"mappings":";;;;;;;;;UAQiB,GAAG;WACT;WACA,OAAO;WACP;;;;;;;;;;UAWM;WACN;WACA;WACA,OAAO;;;;;;;;;;;;;KAcN,OAAO,KAAK,GAAG,KAAK"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "massaman",
3
- "version": "0.3.0",
3
+ "version": "0.5.0",
4
4
  "description": "A comprehensive functional programming library and utilities for TypeScript",
5
5
  "keywords": [
6
6
  "es-toolkit",
@@ -43,6 +43,10 @@
43
43
  "types": "./dist/array/index.d.mts",
44
44
  "import": "./dist/array/index.mjs"
45
45
  },
46
+ "./bigint": {
47
+ "types": "./dist/bigint/index.d.mts",
48
+ "import": "./dist/bigint/index.mjs"
49
+ },
46
50
  "./object": {
47
51
  "types": "./dist/object/index.d.mts",
48
52
  "import": "./dist/object/index.mjs"
@@ -59,6 +63,10 @@
59
63
  "types": "./dist/control/index.d.mts",
60
64
  "import": "./dist/control/index.mjs"
61
65
  },
66
+ "./fp": {
67
+ "types": "./dist/fp/index.d.mts",
68
+ "import": "./dist/fp/index.mjs"
69
+ },
62
70
  "./match": {
63
71
  "types": "./dist/match/index.d.mts",
64
72
  "import": "./dist/match/index.mjs"
@@ -85,25 +93,24 @@
85
93
  "provenance": true
86
94
  },
87
95
  "dependencies": {
88
- "es-toolkit": "1.46.1",
96
+ "es-toolkit": "1.51.0",
89
97
  "ts-pattern": "5.9.0"
90
98
  },
91
99
  "devDependencies": {
92
- "@types/node": "^25.7.0",
93
- "@typescript/native-preview": "7.0.0-dev.20260512.1",
94
- "@vitest/coverage-v8": "^4.1.6",
95
- "tsdown": "0.22.0",
96
- "typescript": "^6.0.3",
97
- "vitest": "^4.1.6",
100
+ "@types/node": "^26.2.0",
101
+ "@vitest/coverage-v8": "^4.1.10",
102
+ "tsdown": "0.22.14",
103
+ "typescript": "^7.0.2",
104
+ "vitest": "^4.1.10",
98
105
  "@massaman/tsconfig": "0.0.0"
99
106
  },
100
107
  "engines": {
101
- "node": ">=24.0.0"
108
+ "node": ">=26.0.0"
102
109
  },
103
110
  "scripts": {
104
111
  "build": "tsdown",
105
112
  "test": "vitest run",
106
113
  "test:watch": "vitest",
107
- "typecheck": "tsgo --noEmit"
114
+ "typecheck": "tsc --noEmit"
108
115
  }
109
116
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-BjmDP8W9.d.mts","names":[],"sources":["../src/conversion/convert.ts"],"mappings":";;AAwBA;;;;;AA8BA;;;;;AAiFA;;;;;AAgBA;;;;;AAaA;iBA5IgB,OAAA,CAAQ,MAAA,YAAkB,KAAA;;;;AA2J1C;;;;;AAwBA;;;;;;;;;;;;iBArJgB,SAAA,CAAU,KAAA;;;;;AA+K1B;;;;;;;;;iBA9FgB,QAAA,CAAS,KAAA;;;;;;;;;;;;;iBAgBT,QAAA,CAAS,KAAA;;;;;;;;;;iBAaT,SAAA,CAAU,KAAA;;;;;;;;;;;;iBAeV,QAAA,CAAS,KAAA;;;;;;;;;;;;;;;;;iBAwBT,OAAA,GAAA,CAAW,KAAA,EAAO,QAAA,CAAS,CAAA,IAAK,CAAA,sBAAuB,CAAA;;;;;;;;;;;;;;iBA0BvD,SAAA,CAAU,KAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-Bp3ol0vr.d.mts","names":[],"sources":["../src/control/attempt.ts","../src/control/result.ts","../src/control/todo.ts","../src/control/unimplemented.ts","../src/control/unreachable.ts"],"mappings":";;;;;;;AAkBA;;;;;;;;;;;;iBAAgB,OAAA,GAAA,CAAW,EAAA,QAAU,CAAA,GAAI,MAAA,CAAO,CAAA;;;AAuBhD;;;;;;;;;;;;;iBAAsB,YAAA,GAAA,CAAgB,EAAA,QAAU,OAAA,CAAQ,CAAA,IAAK,OAAA,CAAQ,MAAA,CAAO,CAAA;;;;;;AAvB5E;;;;;;;;;iBCmBgB,EAAA,GAAA,CAAM,KAAA,EAAO,CAAA,GAAI,EAAA,CAAG,CAAA;;;;;;ADIpC;;;;;;;iBCYgB,GAAA,CAAI,KAAA,YAAiB,GAAA;;;;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DAAA,CACd,EAAA,MAAQ,IAAA,EAAM,CAAA,KAAM,YAAA,CAAa,EAAA,GACjC,EAAA,GAAK,CAAA,EAAG,OAAA,CAAQ,EAAA,MAAQ,YAAA,CAAa,EAAA,GACrC,EAAA,GAAK,CAAA,EAAG,OAAA,CAAQ,EAAA,MAAQ,YAAA,CAAa,EAAA,GACrC,EAAA,GAAK,CAAA,EAAG,OAAA,CAAQ,EAAA,MAAQ,YAAA,CAAa,EAAA,GACrC,EAAA,GAAK,CAAA,EAAG,OAAA,CAAQ,EAAA,MAAQ,YAAA,CAAa,EAAA,GACrC,EAAA,GAAK,CAAA,EAAG,OAAA,CAAQ,EAAA,MAAQ,YAAA,CAAa,EAAA,GACrC,EAAA,GAAK,CAAA,EAAG,OAAA,CAAQ,EAAA,MAAQ,YAAA,CAAa,EAAA,QAChC,IAAA,EAAM,CAAA,KAAM,OAAA,CAAQ,OAAA,CAAQ,EAAA"}
@@ -1,39 +0,0 @@
1
- import { n as Ok$1, t as Err$1 } from "./types-X6LqLWno.mjs";
2
- import { NonExhaustiveError, P, Pattern, isMatching, match } from "ts-pattern";
3
-
4
- //#region src/match/match.d.ts
5
- /**
6
- * Extended ts-pattern `P` namespace. Carries everything ts-pattern exports
7
- * (`P.string`, `P.number`, `P.array`, `P.when`, …) plus `P.ok` / `P.err`
8
- * for matching `Result` values.
9
- *
10
- * Explicit literal-type annotations on the additions (rather than `as const`)
11
- * keep the values non-`readonly`, which ts-pattern's narrowing requires —
12
- * a `readonly` pattern collapses the remaining input to `never` after the
13
- * first arm, breaking exhaustiveness.
14
- *
15
- * For the `P.Pattern<T>` type shorthand, import `Pattern` standalone from
16
- * `massaman/match` — it's the form ts-pattern's own docs recommend.
17
- */
18
- declare const P$1: typeof P & {
19
- ok: {
20
- ok: true;
21
- };
22
- err: {
23
- ok: false;
24
- };
25
- };
26
- /**
27
- * The `Ok` variant of a `Result<T>`. Re-exported here so the value-side
28
- * patterns and the type-side `Ok<T>` live in one module — any consumer
29
- * import gets both type and value namespaces without cross-module merge
30
- * issues (TS2300).
31
- */
32
- type Ok<T> = Ok$1<T>;
33
- /**
34
- * The `Err` variant of a `Result<T>`. See {@link Ok} for the co-location note.
35
- */
36
- type Err = Err$1;
37
- //#endregion
38
- export { Err as a, match as i, Pattern as n, Ok as o, isMatching as r, P$1 as s, NonExhaustiveError as t };
39
- //# sourceMappingURL=index-DtnKhaAD.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-DtnKhaAD.d.mts","names":[],"sources":["../src/match/match.ts"],"mappings":";;;;;;;;AAwDA;;;;;;;;;cAjBa,GAAA,SAAU,CAAA;EAAQ,EAAA;IAAM,EAAA;EAAA;EAAY,GAAA;IAAO,EAAA;EAAA;AAAA;;;;;;;KAY5C,EAAA,MAAQ,IAAA,CAAO,CAAA;;;;KAKf,GAAA,GAAM,KAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-g2aw5tc_.d.mts","names":[],"sources":["../src/types/internal.ts","../src/predicate/combinators.ts","../src/predicate/guards.ts"],"mappings":";;;;;;AAkBA;;;;;;;;ACEA;;;;;;KDFY,mBAAA;;;;;AAAZ;;;;;;;;ACEA;;;;;;;;iBAAgB,OAAA,GAAA,CAAW,UAAA,iBAA2B,KAAA,EAAO,CAAA;AAAA,iBAC7C,OAAA,YAAmB,aAAA,EAAe,KAAA,EAAO,mBAAA,cAAA,CACvD,UAAA,EAAY,EAAA,IACV,KAAA,EAAO,UAAA,CAAW,EAAA,MAAQ,KAAA,IAAS,UAAA,CAAW,EAAA,IAAM,mBAAA,CAAoB,OAAA,CAAQ,EAAA;AAFpF;;;;;;;;;;;;;;;;;AAAA,iBA0BgB,OAAA,GAAA,CAAW,UAAA,iBAA2B,KAAA,EAAO,CAAA;AAAA,iBAC7C,OAAA,YAAmB,aAAA,EAAe,KAAA,EAAO,mBAAA,cAAA,CACvD,UAAA,EAAY,EAAA,IACV,KAAA,EAAO,UAAA,CAAW,EAAA,MAAQ,KAAA,IAAS,UA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;;ADjB3B;;;;;;iBC8BgB,cAAA,CAAe,KAAA,YAAiB,KAAA;;;;AD7BhD;;;;;;iBC0CgB,SAAA,CAAU,KAAA,YAAiB,KAAA;;;;;;;;;;iBAa3B,KAAA,CAAM,KAAA,YAAiB,KAAA"}
@@ -1,20 +0,0 @@
1
- import { clone, cloneDeep, cloneDeepWith, findKey, flattenObject, invert, mapKeys, mapValues, merge, mergeWith, omit, omitBy, pick, pickBy, toCamelCaseKeys, toMerged, toSnakeCaseKeys } from "es-toolkit/object";
2
-
3
- //#region src/object/evolve.d.ts
4
- /**
5
- * Applies a spec of transformation functions to matching keys of an object,
6
- * returning a new object. Keys not in the spec are copied as-is.
7
- *
8
- * @example
9
- * ```ts
10
- * evolve({ name: ' Alice ', age: 29, role: 'admin' }, {
11
- * name: (s) => s.trim(),
12
- * age: (n) => n + 1,
13
- * })
14
- * // { name: 'Alice', age: 30, role: 'admin' }
15
- * ```
16
- */
17
- declare function evolve<T extends Record<string, unknown>>(obj: T, spec: { [K in keyof T]?: (value: T[K]) => T[K] }): T;
18
- //#endregion
19
- export { toSnakeCaseKeys as _, flattenObject as a, mapValues as c, omit as d, omitBy as f, toMerged as g, toCamelCaseKeys as h, findKey as i, merge as l, pickBy as m, cloneDeep as n, invert as o, pick as p, cloneDeepWith as r, mapKeys as s, clone as t, mergeWith as u, evolve as v };
20
- //# sourceMappingURL=index-keGHab-v.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-keGHab-v.d.mts","names":[],"sources":["../src/object/evolve.ts"],"mappings":";;;;;;AAaA;;;;;;;;;;iBAAgB,MAAA,WAAiB,MAAA,kBAAA,CAC/B,GAAA,EAAK,CAAA,EACL,IAAA,gBAAoB,CAAA,KAAM,KAAA,EAAO,CAAA,CAAE,CAAA,MAAO,CAAA,CAAE,CAAA,MAC3C,CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-mfIoxwxy.d.mts","names":[],"sources":["../src/array/adjust.ts","../src/array/dropRepeats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AAA,EAAG,CAAA,WAAY,IAAA,EAAM,CAAA,GAAI,CAAA"}
@@ -1,44 +0,0 @@
1
- import { NonExhaustiveError, P, Pattern, isMatching, match } from "ts-pattern";
2
- //#region src/match/match.ts
3
- /**
4
- * Extends ts-pattern's `P` namespace with `P.ok` and `P.err` — structural
5
- * patterns for matching a `Result` inside `match()`.
6
- *
7
- * Mirrors Rust's `Ok(value)` / `Err(error)` match arms, but uses the
8
- * namespace-property form (`P.ok` / `P.err`) so it doesn't collide with
9
- * the lowercase `ok()` / `err()` constructors from `massaman/control`.
10
- *
11
- * @example
12
- * ```ts
13
- * import { match, P, attempt } from 'massaman'
14
- *
15
- * match(attempt(() => JSON.parse(raw)))
16
- * .with(P.ok, ({ value }) => use(value))
17
- * .with(P.err, ({ error }) => log(error))
18
- * .exhaustive()
19
- * ```
20
- */
21
- const okPattern = { ok: true };
22
- const errPattern = { ok: false };
23
- /**
24
- * Extended ts-pattern `P` namespace. Carries everything ts-pattern exports
25
- * (`P.string`, `P.number`, `P.array`, `P.when`, …) plus `P.ok` / `P.err`
26
- * for matching `Result` values.
27
- *
28
- * Explicit literal-type annotations on the additions (rather than `as const`)
29
- * keep the values non-`readonly`, which ts-pattern's narrowing requires —
30
- * a `readonly` pattern collapses the remaining input to `never` after the
31
- * first arm, breaking exhaustiveness.
32
- *
33
- * For the `P.Pattern<T>` type shorthand, import `Pattern` standalone from
34
- * `massaman/match` — it's the form ts-pattern's own docs recommend.
35
- */
36
- const P$1 = {
37
- ...P,
38
- ok: okPattern,
39
- err: errPattern
40
- };
41
- //#endregion
42
- export { P$1 as a, match as i, Pattern as n, isMatching as r, NonExhaustiveError as t };
43
-
44
- //# sourceMappingURL=match-CG_v2C4Q.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"match-CG_v2C4Q.mjs","names":["P","TsP"],"sources":["../src/match/match.ts"],"sourcesContent":["/**\n * Extends ts-pattern's `P` namespace with `P.ok` and `P.err` — structural\n * patterns for matching a `Result` inside `match()`.\n *\n * Mirrors Rust's `Ok(value)` / `Err(error)` match arms, but uses the\n * namespace-property form (`P.ok` / `P.err`) so it doesn't collide with\n * the lowercase `ok()` / `err()` constructors from `massaman/control`.\n *\n * @example\n * ```ts\n * import { match, P, attempt } from 'massaman'\n *\n * match(attempt(() => JSON.parse(raw)))\n * .with(P.ok, ({ value }) => use(value))\n * .with(P.err, ({ error }) => log(error))\n * .exhaustive()\n * ```\n */\n\nimport { P as TsP } from 'ts-pattern'\n\nimport type { Err as ErrType, Ok as OkType } from '../control/types.js'\n\nconst okPattern: { ok: true } = { ok: true }\nconst errPattern: { ok: false } = { ok: false }\n\n/**\n * Extended ts-pattern `P` namespace. Carries everything ts-pattern exports\n * (`P.string`, `P.number`, `P.array`, `P.when`, …) plus `P.ok` / `P.err`\n * for matching `Result` values.\n *\n * Explicit literal-type annotations on the additions (rather than `as const`)\n * keep the values non-`readonly`, which ts-pattern's narrowing requires —\n * a `readonly` pattern collapses the remaining input to `never` after the\n * first arm, breaking exhaustiveness.\n *\n * For the `P.Pattern<T>` type shorthand, import `Pattern` standalone from\n * `massaman/match` — it's the form ts-pattern's own docs recommend.\n */\nexport const P: typeof TsP & { ok: { ok: true }; err: { ok: false } } = {\n ...TsP,\n ok: okPattern,\n err: errPattern,\n}\n\n/**\n * The `Ok` variant of a `Result<T>`. Re-exported here so the value-side\n * patterns and the type-side `Ok<T>` live in one module — any consumer\n * import gets both type and value namespaces without cross-module merge\n * issues (TS2300).\n */\nexport type Ok<T> = OkType<T>\n\n/**\n * The `Err` variant of a `Result<T>`. See {@link Ok} for the co-location note.\n */\nexport type Err = ErrType\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAuBA,MAAM,YAA0B,EAAE,IAAI,MAAM;AAC5C,MAAM,aAA4B,EAAE,IAAI,OAAO;;;;;;;;;;;;;;AAe/C,MAAaA,MAA2D;CACtE,GAAGC;CACH,IAAI;CACJ,KAAK;CACN"}