rubico 2.4.1 → 2.4.2
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/README.md +6 -0
- package/dist/Transducer.es.js +1 -1
- package/dist/Transducer.es.min.js +2 -2
- package/dist/Transducer.js +1 -1
- package/dist/Transducer.min.js +1 -1
- package/dist/Transducer.mjs +1 -1
- package/dist/__.es.js +1 -1
- package/dist/__.es.min.js +1 -1
- package/dist/__.js +1 -1
- package/dist/__.min.js +1 -1
- package/dist/__.mjs +1 -1
- package/dist/all.es.js +1 -1
- package/dist/all.es.min.js +2 -2
- package/dist/all.js +1 -1
- package/dist/all.min.js +2 -2
- package/dist/all.mjs +1 -1
- package/dist/always.es.js +1 -1
- package/dist/always.es.min.js +1 -1
- package/dist/always.js +1 -1
- package/dist/always.min.js +1 -1
- package/dist/always.mjs +1 -1
- package/dist/and.es.js +1 -1
- package/dist/and.es.min.js +2 -2
- package/dist/and.js +1 -1
- package/dist/and.min.js +2 -2
- package/dist/and.mjs +1 -1
- package/dist/assign.es.js +1 -1
- package/dist/assign.es.min.js +2 -2
- package/dist/assign.js +1 -1
- package/dist/assign.min.js +1 -1
- package/dist/assign.mjs +1 -1
- package/dist/compose.es.js +1 -1
- package/dist/compose.es.min.js +2 -2
- package/dist/compose.js +1 -1
- package/dist/compose.min.js +1 -1
- package/dist/compose.mjs +1 -1
- package/dist/curry.es.js +1 -1
- package/dist/curry.es.min.js +1 -1
- package/dist/curry.js +1 -1
- package/dist/curry.min.js +1 -1
- package/dist/curry.mjs +1 -1
- package/dist/eq.es.js +1 -1
- package/dist/eq.es.min.js +1 -1
- package/dist/eq.js +1 -1
- package/dist/eq.min.js +1 -1
- package/dist/eq.mjs +1 -1
- package/dist/every.es.js +1 -1
- package/dist/every.es.min.js +1 -1
- package/dist/every.js +1 -1
- package/dist/every.min.js +1 -1
- package/dist/every.mjs +1 -1
- package/dist/filter.es.js +1 -1
- package/dist/filter.es.min.js +1 -1
- package/dist/filter.js +1 -1
- package/dist/filter.min.js +1 -1
- package/dist/filter.mjs +1 -1
- package/dist/flatMap.es.js +1 -1
- package/dist/flatMap.es.min.js +2 -2
- package/dist/flatMap.js +1 -1
- package/dist/flatMap.min.js +1 -1
- package/dist/flatMap.mjs +1 -1
- package/dist/forEach.es.js +1 -1
- package/dist/forEach.es.min.js +1 -1
- package/dist/forEach.js +1 -1
- package/dist/forEach.min.js +1 -1
- package/dist/forEach.mjs +1 -1
- package/dist/get.es.js +1 -1
- package/dist/get.es.min.js +2 -2
- package/dist/get.js +1 -1
- package/dist/get.min.js +1 -1
- package/dist/get.mjs +1 -1
- package/dist/gt.es.js +1 -1
- package/dist/gt.es.min.js +1 -1
- package/dist/gt.js +1 -1
- package/dist/gt.min.js +1 -1
- package/dist/gt.mjs +1 -1
- package/dist/gte.es.js +1 -1
- package/dist/gte.es.min.js +1 -1
- package/dist/gte.js +1 -1
- package/dist/gte.min.js +1 -1
- package/dist/gte.mjs +1 -1
- package/dist/lt.es.js +1 -1
- package/dist/lt.es.min.js +1 -1
- package/dist/lt.js +1 -1
- package/dist/lt.min.js +1 -1
- package/dist/lt.mjs +1 -1
- package/dist/lte.es.js +1 -1
- package/dist/lte.es.min.js +1 -1
- package/dist/lte.js +1 -1
- package/dist/lte.min.js +1 -1
- package/dist/lte.mjs +1 -1
- package/dist/map.es.js +1 -1
- package/dist/map.es.min.js +1 -1
- package/dist/map.js +1 -1
- package/dist/map.min.js +1 -1
- package/dist/map.mjs +1 -1
- package/dist/not.es.js +1 -1
- package/dist/not.es.min.js +2 -2
- package/dist/not.js +1 -1
- package/dist/not.min.js +2 -2
- package/dist/not.mjs +1 -1
- package/dist/omit.es.js +1 -1
- package/dist/omit.es.min.js +2 -2
- package/dist/omit.js +1 -1
- package/dist/omit.min.js +1 -1
- package/dist/omit.mjs +1 -1
- package/dist/or.es.js +1 -1
- package/dist/or.es.min.js +2 -2
- package/dist/or.js +1 -1
- package/dist/or.min.js +2 -2
- package/dist/or.mjs +1 -1
- package/dist/pick.es.js +1 -1
- package/dist/pick.es.min.js +2 -2
- package/dist/pick.js +1 -1
- package/dist/pick.min.js +1 -1
- package/dist/pick.mjs +1 -1
- package/dist/pipe.es.js +1 -1
- package/dist/pipe.es.min.js +2 -2
- package/dist/pipe.js +1 -1
- package/dist/pipe.min.js +1 -1
- package/dist/pipe.mjs +1 -1
- package/dist/reduce.es.js +1 -1
- package/dist/reduce.es.min.js +2 -2
- package/dist/reduce.js +1 -1
- package/dist/reduce.min.js +1 -1
- package/dist/reduce.mjs +1 -1
- package/dist/rubico.es.js +1 -1
- package/dist/rubico.es.min.js +2 -2
- package/dist/rubico.global.js +1 -1
- package/dist/rubico.global.min.js +2 -2
- package/dist/rubico.js +1 -1
- package/dist/rubico.min.js +2 -2
- package/dist/rubico.mjs +1 -1
- package/dist/set.es.js +1 -1
- package/dist/set.es.min.js +1 -1
- package/dist/set.js +1 -1
- package/dist/set.min.js +1 -1
- package/dist/set.mjs +1 -1
- package/dist/some.es.js +1 -1
- package/dist/some.es.min.js +1 -1
- package/dist/some.js +1 -1
- package/dist/some.min.js +1 -1
- package/dist/some.mjs +1 -1
- package/dist/switchCase.es.js +1 -1
- package/dist/switchCase.es.min.js +2 -2
- package/dist/switchCase.js +1 -1
- package/dist/switchCase.min.js +1 -1
- package/dist/switchCase.mjs +1 -1
- package/dist/tap.es.js +1 -1
- package/dist/tap.es.min.js +2 -2
- package/dist/tap.js +1 -1
- package/dist/tap.min.js +2 -2
- package/dist/tap.mjs +1 -1
- package/dist/thunkify.es.js +1 -1
- package/dist/thunkify.es.min.js +2 -2
- package/dist/thunkify.js +1 -1
- package/dist/thunkify.min.js +1 -1
- package/dist/thunkify.mjs +1 -1
- package/dist/transform.es.js +1 -1
- package/dist/transform.es.min.js +2 -2
- package/dist/transform.js +1 -1
- package/dist/transform.min.js +1 -1
- package/dist/transform.mjs +1 -1
- package/dist/tryCatch.es.js +1 -1
- package/dist/tryCatch.es.min.js +1 -1
- package/dist/tryCatch.js +1 -1
- package/dist/tryCatch.min.js +1 -1
- package/dist/tryCatch.mjs +1 -1
- package/dist/x/append.es.js +1 -1
- package/dist/x/append.es.min.js +1 -1
- package/dist/x/append.js +1 -1
- package/dist/x/append.min.js +1 -1
- package/dist/x/append.mjs +1 -1
- package/dist/x/callProp.es.js +1 -1
- package/dist/x/callProp.es.min.js +1 -1
- package/dist/x/callProp.js +1 -1
- package/dist/x/callProp.min.js +1 -1
- package/dist/x/callProp.mjs +1 -1
- package/dist/x/defaultsDeep.es.js +1 -1
- package/dist/x/defaultsDeep.es.min.js +1 -1
- package/dist/x/defaultsDeep.js +1 -1
- package/dist/x/defaultsDeep.min.js +1 -1
- package/dist/x/defaultsDeep.mjs +1 -1
- package/dist/x/differenceWith.es.js +1 -1
- package/dist/x/differenceWith.es.min.js +2 -2
- package/dist/x/differenceWith.js +1 -1
- package/dist/x/differenceWith.min.js +1 -1
- package/dist/x/differenceWith.mjs +1 -1
- package/dist/x/filterOut.es.js +1 -1
- package/dist/x/filterOut.es.min.js +2 -2
- package/dist/x/filterOut.js +1 -1
- package/dist/x/filterOut.min.js +2 -2
- package/dist/x/filterOut.mjs +1 -1
- package/dist/x/find.es.js +1 -1
- package/dist/x/find.es.min.js +1 -1
- package/dist/x/find.js +1 -1
- package/dist/x/find.min.js +1 -1
- package/dist/x/find.mjs +1 -1
- package/dist/x/findIndex.es.js +1 -1
- package/dist/x/findIndex.es.min.js +2 -2
- package/dist/x/findIndex.js +1 -1
- package/dist/x/findIndex.min.js +1 -1
- package/dist/x/findIndex.mjs +1 -1
- package/dist/x/first.es.js +1 -1
- package/dist/x/first.es.min.js +1 -1
- package/dist/x/first.js +1 -1
- package/dist/x/first.min.js +1 -1
- package/dist/x/first.mjs +1 -1
- package/dist/x/flatten.es.js +1 -1
- package/dist/x/flatten.es.min.js +2 -2
- package/dist/x/flatten.js +1 -1
- package/dist/x/flatten.min.js +1 -1
- package/dist/x/flatten.mjs +1 -1
- package/dist/x/groupBy.es.js +1 -1
- package/dist/x/groupBy.es.min.js +2 -2
- package/dist/x/groupBy.js +1 -1
- package/dist/x/groupBy.min.js +1 -1
- package/dist/x/groupBy.mjs +1 -1
- package/dist/x/has.es.js +1 -1
- package/dist/x/has.es.min.js +1 -1
- package/dist/x/has.js +1 -1
- package/dist/x/has.min.js +1 -1
- package/dist/x/has.mjs +1 -1
- package/dist/x/identity.es.js +1 -1
- package/dist/x/identity.es.min.js +1 -1
- package/dist/x/identity.js +1 -1
- package/dist/x/identity.min.js +1 -1
- package/dist/x/identity.mjs +1 -1
- package/dist/x/includes.es.js +1 -1
- package/dist/x/includes.es.min.js +2 -2
- package/dist/x/includes.js +1 -1
- package/dist/x/includes.min.js +1 -1
- package/dist/x/includes.mjs +1 -1
- package/dist/x/isDeepEqual.es.js +1 -1
- package/dist/x/isDeepEqual.es.min.js +2 -2
- package/dist/x/isDeepEqual.js +1 -1
- package/dist/x/isDeepEqual.min.js +1 -1
- package/dist/x/isDeepEqual.mjs +1 -1
- package/dist/x/isEmpty.es.js +1 -1
- package/dist/x/isEmpty.es.min.js +1 -1
- package/dist/x/isEmpty.js +1 -1
- package/dist/x/isEmpty.min.js +1 -1
- package/dist/x/isEmpty.mjs +1 -1
- package/dist/x/isEqual.es.js +1 -1
- package/dist/x/isEqual.es.min.js +1 -1
- package/dist/x/isEqual.js +1 -1
- package/dist/x/isEqual.min.js +1 -1
- package/dist/x/isEqual.mjs +1 -1
- package/dist/x/isFunction.es.js +1 -1
- package/dist/x/isFunction.es.min.js +1 -1
- package/dist/x/isFunction.js +1 -1
- package/dist/x/isFunction.min.js +1 -1
- package/dist/x/isFunction.mjs +1 -1
- package/dist/x/isIn.es.js +1 -1
- package/dist/x/isIn.es.min.js +2 -2
- package/dist/x/isIn.js +1 -1
- package/dist/x/isIn.min.js +1 -1
- package/dist/x/isIn.mjs +1 -1
- package/dist/x/isObject.es.js +1 -1
- package/dist/x/isObject.es.min.js +1 -1
- package/dist/x/isObject.js +1 -1
- package/dist/x/isObject.min.js +1 -1
- package/dist/x/isObject.mjs +1 -1
- package/dist/x/isString.es.js +1 -1
- package/dist/x/isString.es.min.js +1 -1
- package/dist/x/isString.js +1 -1
- package/dist/x/isString.min.js +1 -1
- package/dist/x/isString.mjs +1 -1
- package/dist/x/keys.es.js +1 -1
- package/dist/x/keys.es.min.js +1 -1
- package/dist/x/keys.js +1 -1
- package/dist/x/keys.min.js +1 -1
- package/dist/x/keys.mjs +1 -1
- package/dist/x/last.es.js +1 -1
- package/dist/x/last.es.min.js +1 -1
- package/dist/x/last.js +1 -1
- package/dist/x/last.min.js +1 -1
- package/dist/x/last.mjs +1 -1
- package/dist/x/maxBy.es.js +1 -1
- package/dist/x/maxBy.es.min.js +2 -2
- package/dist/x/maxBy.js +1 -1
- package/dist/x/maxBy.min.js +1 -1
- package/dist/x/maxBy.mjs +1 -1
- package/dist/x/noop.es.js +1 -1
- package/dist/x/noop.es.min.js +1 -1
- package/dist/x/noop.js +1 -1
- package/dist/x/noop.min.js +1 -1
- package/dist/x/noop.mjs +1 -1
- package/dist/x/pluck.es.js +1 -1
- package/dist/x/pluck.es.min.js +2 -2
- package/dist/x/pluck.js +1 -1
- package/dist/x/pluck.min.js +1 -1
- package/dist/x/pluck.mjs +1 -1
- package/dist/x/prepend.es.js +1 -1
- package/dist/x/prepend.es.min.js +1 -1
- package/dist/x/prepend.js +1 -1
- package/dist/x/prepend.min.js +1 -1
- package/dist/x/prepend.mjs +1 -1
- package/dist/x/size.es.js +1 -1
- package/dist/x/size.es.min.js +1 -1
- package/dist/x/size.js +1 -1
- package/dist/x/size.min.js +1 -1
- package/dist/x/size.mjs +1 -1
- package/dist/x/trace.es.js +1 -1
- package/dist/x/trace.es.min.js +2 -2
- package/dist/x/trace.js +1 -1
- package/dist/x/trace.min.js +2 -2
- package/dist/x/trace.mjs +1 -1
- package/dist/x/unionWith.es.js +1 -1
- package/dist/x/unionWith.es.min.js +1 -1
- package/dist/x/unionWith.js +1 -1
- package/dist/x/unionWith.min.js +1 -1
- package/dist/x/unionWith.mjs +1 -1
- package/dist/x/uniq.es.js +1 -1
- package/dist/x/uniq.es.min.js +1 -1
- package/dist/x/uniq.js +1 -1
- package/dist/x/uniq.min.js +1 -1
- package/dist/x/uniq.mjs +1 -1
- package/dist/x/unless.es.js +1 -1
- package/dist/x/unless.es.min.js +2 -2
- package/dist/x/unless.js +1 -1
- package/dist/x/unless.min.js +1 -1
- package/dist/x/unless.mjs +1 -1
- package/dist/x/values.es.js +1 -1
- package/dist/x/values.es.min.js +1 -1
- package/dist/x/values.js +1 -1
- package/dist/x/values.min.js +1 -1
- package/dist/x/values.mjs +1 -1
- package/dist/x/when.es.js +1 -1
- package/dist/x/when.es.min.js +2 -2
- package/dist/x/when.js +1 -1
- package/dist/x/when.min.js +1 -1
- package/dist/x/when.mjs +1 -1
- package/es.js +1 -1
- package/index.js +1 -1
- package/package.json +8 -7
package/dist/flatMap.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
|
-
const isPromise=e=>null!=e&&"function"==typeof e.then,isArray=Array.isArray,objectValues=Object.values,objectProto=Object.prototype,nativeObjectToString=objectProto.toString,objectToString=e=>nativeObjectToString.call(e),generatorFunctionTag="[object GeneratorFunction]",isGeneratorFunction=e=>objectToString(e)==generatorFunctionTag,asyncGeneratorFunctionTag="[object AsyncGeneratorFunction]",isAsyncGeneratorFunction=e=>objectToString(e)==asyncGeneratorFunctionTag,__=Symbol.for("placeholder"),curry3ResolveArg0=(e,r,t)=>function(n){return e(n,r,t)},curry3ResolveArg1=(e,r,t)=>function(n){return e(r,n,t)},curry3ResolveArg2=(e,r,t)=>function(n){return e(r,t,n)},curry3=function(e,r,t,n){return r==__?curry3ResolveArg0(e,t,n):t==__?curry3ResolveArg1(e,r,n):curry3ResolveArg2(e,r,t)},iteratorReduceAsync=async function(e,r,t){let n=e.next();if(n.done)return t;for(;!n.done;)t=r(t,n.value),isPromise(t)&&(t=await t),n=e.next();return t},iteratorReduce=function(e,r,t){let n=e.next();if(n.done)return t;for(void 0===t&&(t=n.value,n=e.next());!n.done;){if(t=r(t,n.value),isPromise(t))return t.then(curry3(iteratorReduceAsync,e,r,__));n=e.next()}return t},asyncIteratorReduce=async function(e,r,t){let n=await e.next();if(n.done)return t;for(void 0===t&&(t=n.value,n=await e.next());!n.done;)t=await r(t,n.value),n=await e.next();return t},symbolIterator=Symbol.iterator,symbolAsyncIterator=Symbol.asyncIterator,curry2ResolveArg0=(e,r)=>function(t){return e(t,r)},curry2ResolveArg1=(e,r)=>function(t){return e(r,t)},curry2=function(e,r,t){return r==__?curry2ResolveArg0(e,t):curry2ResolveArg1(e,r)},curryArgs3ResolveArgs0=(e,r,t)=>function(...n){return e(n,r,t)},curryArgs3ResolveArgs1=(e,r,t)=>function(...n){return e(r,n,t)},curryArgs3ResolveArgs2=(e,r,t)=>function(...n){return e(r,t,n)},curryArgs3=function(e,r,t,n){return r==__?curryArgs3ResolveArgs0(e,t,n):t==__?curryArgs3ResolveArgs1(e,r,n):curryArgs3ResolveArgs2(e,r,t)},curry4ResolveArg0=(e,r,t,n)=>function(o){return e(o,r,t,n)},curry4ResolveArg1=(e,r,t,n)=>function(o){return e(r,o,t,n)},curry4ResolveArg2=(e,r,t,n)=>function(o){return e(r,t,o,n)},curry4ResolveArg3=(e,r,t,n)=>function(o){return e(r,t,n,o)},curry4=function(e,r,t,n,o){return r==__?curry4ResolveArg0(e,t,n,o):t==__?curry4ResolveArg1(e,r,n,o):n==__?curry4ResolveArg2(e,r,t,o):curry4ResolveArg3(e,r,t,n)},arrayReduceAsync=async function(e,r,t,n){const o=e.length;for(;++n<o;)t=r(t,e[n],n,e),isPromise(t)&&(t=await t);return t},arrayReduce=function(e,r,t){const n=e.length;let o=-1;for(void 0===t&&(t=e[++o]);++o<n;)if(t=r(t,e[o],o,e),isPromise(t))return t.then(curry4(arrayReduceAsync,e,r,__,o));return t},curry5ResolveArg0=(e,r,t,n,o)=>function(c){return e(c,r,t,n,o)},curry5ResolveArg1=(e,r,t,n,o)=>function(c){return e(r,c,t,n,o)},curry5ResolveArg2=(e,r,t,n,o)=>function(c){return e(r,t,c,n,o)},curry5ResolveArg3=(e,r,t,n,o)=>function(c){return e(r,t,n,c,o)},curry5ResolveArg4=(e,r,t,n,o)=>function(c){return e(r,t,n,o,c)},curry5=function(e,r,t,n,o,c){return r==__?curry5ResolveArg0(e,t,n,o,c):t==__?curry5ResolveArg1(e,r,n,o,c):n==__?curry5ResolveArg2(e,r,t,o,c):o==__?curry5ResolveArg3(e,r,t,n,c):curry5ResolveArg4(e,r,t,n,o)},objectKeys=Object.keys,objectReduceAsync=async function(e,r,t,n,o){const c=n.length;for(;++o<c;){const c=n[o];t=r(t,e[c],c,e),isPromise(t)&&(t=await t)}return t},objectReduce=function(e,r,t){const n=objectKeys(e),o=n.length;let c=-1;for(void 0===t&&(t=e[n[++c]]);++c<o;){const o=n[c];if(t=r(t,e[o],o,e),isPromise(t))return t.then((s=objectReduceAsync,u=r,a=__,l=n,y=c,(i=e)==__?curry5ResolveArg0(s,u,a,l,y):u==__?curry5ResolveArg1(s,i,a,l,y):a==__?curry5ResolveArg2(s,i,u,l,y):l==__?curry5ResolveArg3(s,i,u,a,y):curry5ResolveArg4(s,i,u,a,l)))}var s,i,u,a,l,y;return t},mapReduceAsync=async function(e,r,t,n){for(const[o,c]of n)t=r(t,c,o,e),isPromise(t)&&(t=await t);return t},mapReduce=function(e,r,t){const n=e.entries();if(void 0===t){const e=n.next();if(e.done)return t;t=e.value[1]}for(const[o,c]of n)if(t=r(t,c,o,e),isPromise(t))return t.then(curry4(mapReduceAsync,e,r,__,n));return t},reducerConcat=(e,r)=>function(t,n){const o=e(t,n);return isPromise(o)?o.then(curry2(r,__,n)):r(o,n)},genericReduce=function(e,r,t){return isArray(e)?arrayReduce(e,r,t):null==e?void 0===t?curry2(r,e,__):r(t,e):e.constructor==Map?mapReduce(e,r,t):"function"==typeof e[symbolIterator]?iteratorReduce(e[symbolIterator](),r,t):"function"==typeof e[symbolAsyncIterator]?asyncIteratorReduce(e[symbolAsyncIterator](),r,t):"function"==typeof e.reduce?e.reduce(r,t):"function"==typeof e.chain?e.chain(curry2(r,t,__)):"function"==typeof e.flatMap?e.flatMap(curry2(r,t,__)):e.constructor==Object?objectReduce(e,r,t):void 0===t?curry2(r,e,__):r(t,e)},arrayPush=function(e,r){return e.push(r),e},FlatMappingIterator=function(e,r){let t=[],n=0;return{[symbolIterator](){return this},next(){if(n<t.length){const e=t[n];return n+=1,{value:e,done:!1}}const o=e.next();if(o.done)return o;const c=genericReduce(r(o.value),arrayPush,[]);return c.length>1&&(t=c,n=1),{value:c[0],done:!1}}}},promiseRace=Promise.race.bind(Promise),sleep=e=>new Promise((r=>{setTimeout(r,e)})),FlatMappingAsyncIterator=function(e,r){const t=[],n=new Set;return{isAsyncIteratorDone:!1,[symbolAsyncIterator](){return this},toString:()=>"[object FlatMappingAsyncIterator]",async next(){for(;!this.isAsyncIteratorDone||t.length>0||n.size>0;){if(!this.isAsyncIteratorDone){const{value:o,done:c}=await e.next();if(c)this.isAsyncIteratorDone=c;else{const e=r(o);if(isPromise(e)){const r=e.then(curry3(genericReduce,__,arrayPush,t)).then((()=>n.delete(r)));n.add(r)}else{const r=genericReduce(e,arrayPush,t);if(isPromise(r)){const e=r.then((()=>n.delete(e)));n.add(e)}}}}if(t.length>0)return{value:t.shift(),done:!1};n.size>0&&await promiseRace([sleep(1e3),...n])}return{value:void 0,done:!0}}}},always=e=>function(){return e},getArg1=(e,r)=>r,identity=e=>e,promiseAll=Promise.all.bind(Promise),funcConcatSync=(e,r)=>function(...t){return r(e(...t))},asyncIteratorForEach=async function(e,r){const t=[];for await(const n of e){const e=r(n);isPromise(e)&&t.push(e)}return 0==t.length?e:promiseAll(t).then(always(e))},arrayFlatten=function(e){const r=e.length,t=[],n=[];let o=-1;for(;++o<r;){const r=e[o];if(isArray(r)){const e=r.length;let t=-1;for(;++t<e;)n.push(r[t])}else if(null==r)n.push(r);else if("function"==typeof r.then)t.push(r.then(curry2(arrayPush,n,__)));else if("function"==typeof r[symbolIterator])for(const e of r)n.push(e);else if("function"==typeof r[symbolAsyncIterator])t.push(asyncIteratorForEach(r[symbolAsyncIterator](),curry2(arrayPush,n,__)));else if("function"==typeof r.chain){const e=r.chain(identity);isPromise(e)?t.push(e.then(curry2(arrayPush,n,__))):n.push(e)}else if("function"==typeof r.flatMap){const e=r.flatMap(identity);isPromise(e)?t.push(e.then(curry2(arrayPush,n,__))):n.push(e)}else if("function"==typeof r.reduce){const e=r.reduce(funcConcatSync(getArg1,curry2(arrayPush,n,__)),null);isPromise(e)&&t.push(e)}else if(r.constructor==Object)for(const e in r)n.push(r[e]);else n.push(r)}return 0==t.length?n:promiseAll(t).then(always(n))},arrayMap=function(e,r){const t=e.length,n=Array(t);let o=-1,c=!1;for(;++o<t;){const t=r(e[o],o,e);isPromise(t)&&(c=!0),n[o]=t}return c?promiseAll(n):n},arrayFlatMap=function(e,r){const t=arrayMap(e,r);return isPromise(t)?t.then(arrayFlatten):arrayFlatten(t)},promiseObjectAllExecutor=e=>function(r){const t={};let n=0;for(const o in e){const c=e[o];isPromise(c)?(n+=1,c.then((e=>function(o){t[e]=o,n-=1,0==n&&r(t)})(o))):t[o]=c}0==n&&r(t)},promiseObjectAll=e=>new Promise(promiseObjectAllExecutor(e)),objectMap=function(e,r){const t={};let n=!1;for(const o in e){const c=r(e[o],o,e);isPromise(c)&&(n=!0),t[o]=c}return n?promiseObjectAll(t):t},objectAssign=Object.assign,objectFlatten=function(e){const r=[],t={},n=curry2(objectAssign,t,__),o=funcConcatSync(getArg1,n);for(const c in e){const s=e[c];if(null!=s)if("function"==typeof s[symbolIterator])for(const e of s)objectAssign(t,e);else if("function"==typeof s[symbolAsyncIterator])r.push(asyncIteratorForEach(s[symbolAsyncIterator](),n));else if("function"==typeof s.chain){const e=s.chain(identity);isPromise(e)?r.push(e.then(n)):objectAssign(t,e)}else if("function"==typeof s.flatMap){const e=s.flatMap(identity);isPromise(e)?r.push(e.then(n)):n(e)}else if("function"==typeof s.reduce){const e=s.reduce(o,null);isPromise(e)&&r.push(e)}else objectAssign(t,s)}return 0==r.length?t:promiseAll(r).then((()=>t))},objectFlatMap=function(e,r){const t=objectMap(e,r);return isPromise(t)?t.then(objectFlatten):objectFlatten(t)},callPropUnary=(e,r,t)=>e[r](t),setMap=function(e,r){const t=new Set,n=[];for(const o of e){const c=r(o,o,e);isPromise(c)?n.push(c.then(curry3(callPropUnary,t,"add",__))):t.add(c)}return 0==n.length?t:promiseAll(n).then(always(t))},setFlatten=function(e){e.size;const r=[],t=new Set,n=(e,r)=>t.add(r),o=curry3(callPropUnary,t,"add",__);for(const c of e)if(isArray(c)){const e=c.length;let r=-1;for(;++r<e;)t.add(c[r])}else if(null==c)t.add(c);else if("function"==typeof c[symbolIterator])for(const e of c)t.add(e);else if("function"==typeof c[symbolAsyncIterator])r.push(asyncIteratorForEach(c[symbolAsyncIterator](),o));else if("function"==typeof c.chain){const e=c.chain(identity);isPromise(e)?r.push(e.then(o)):t.add(e)}else if("function"==typeof c.flatMap){const e=c.flatMap(identity);isPromise(e)?r.push(e.then(o)):t.add(e)}else if("function"==typeof c.reduce){const e=c.reduce(n,null);isPromise(e)&&r.push(e)}else if(c.constructor==Object)for(const e in c)t.add(c[e]);else t.add(c);return 0==r.length?t:promiseAll(r).then((()=>t))},setFlatMap=function(e,r){const t=setMap(e,r);return isPromise(t)?t.then(setFlatten):setFlatten(t)},funcConcat=(e,r)=>function(...t){const n=e(...t);return isPromise(n)?n.then(r):r(n)},arrayJoin=(e,r)=>e.join(r),arrayFlattenToString=funcConcat(arrayFlatten,curry2(arrayJoin,__,"")),stringFlatMap=function(e,r){const t=arrayMap(e,r);return isPromise(t)?t.then(arrayFlattenToString):arrayFlattenToString(t)},_flatMap=function(e,r){if(isArray(e))return arrayFlatMap(e,r);if(null==e)return r(e);if("function"==typeof e.then)return e.then(r);if("function"==typeof e.next)return symbolIterator in e?FlatMappingIterator(e,r):FlatMappingAsyncIterator(e,r);if("function"==typeof e.chain)return e.chain(r);if("function"==typeof e.flatMap)return e.flatMap(r);const t=e.constructor;return t==Object?objectFlatMap(e,r):t==Set?setFlatMap(e,r):"string"==typeof e||t==String?stringFlatMap(e,r):r(e)},flatMap=(e,r)=>"function"==typeof e?curry2(_flatMap,__,e):isPromise(e)?e.then(curry2(_flatMap,__,r)):_flatMap(e,r);export default flatMap;
|
|
7
|
+
const isPromise=e=>null!=e&&"function"==typeof e.then,isArray=Array.isArray,objectValues=Object.values,objectProto=Object.prototype,nativeObjectToString=objectProto.toString,objectToString=e=>nativeObjectToString.call(e),generatorFunctionTag="[object GeneratorFunction]",isGeneratorFunction=e=>objectToString(e)==generatorFunctionTag,asyncGeneratorFunctionTag="[object AsyncGeneratorFunction]",isAsyncGeneratorFunction=e=>objectToString(e)==asyncGeneratorFunctionTag,__=Symbol.for("placeholder"),curry3ResolveArg0=(e,r,t)=>function(n){return e(n,r,t)},curry3ResolveArg1=(e,r,t)=>function(n){return e(r,n,t)},curry3ResolveArg2=(e,r,t)=>function(n){return e(r,t,n)},curry3=function(e,r,t,n){return r==__?curry3ResolveArg0(e,t,n):t==__?curry3ResolveArg1(e,r,n):curry3ResolveArg2(e,r,t)},iteratorReduceAsync=async function(e,r,t){let n=e.next();if(n.done)return t;for(;!n.done;)t=r(t,n.value),isPromise(t)&&(t=await t),n=e.next();return t},iteratorReduce=function(e,r,t){let n=e.next();if(n.done)return t;for(void 0===t&&(t=n.value,n=e.next());!n.done;){if(t=r(t,n.value),isPromise(t))return t.then(curry3(iteratorReduceAsync,e,r,__));n=e.next()}return t},asyncIteratorReduce=async function(e,r,t){let n=await e.next();if(n.done)return t;for(void 0===t&&(t=n.value,n=await e.next());!n.done;)t=await r(t,n.value),n=await e.next();return t},symbolIterator=Symbol.iterator,symbolAsyncIterator=Symbol.asyncIterator,curry2ResolveArg0=(e,r)=>function(t){return e(t,r)},curry2ResolveArg1=(e,r)=>function(t){return e(r,t)},curry2=function(e,r,t){return r==__?curry2ResolveArg0(e,t):curry2ResolveArg1(e,r)},curryArgs3ResolveArgs0=(e,r,t)=>function(...n){return e(n,r,t)},curryArgs3ResolveArgs1=(e,r,t)=>function(...n){return e(r,n,t)},curryArgs3ResolveArgs2=(e,r,t)=>function(...n){return e(r,t,n)},curryArgs3=function(e,r,t,n){return r==__?curryArgs3ResolveArgs0(e,t,n):t==__?curryArgs3ResolveArgs1(e,r,n):curryArgs3ResolveArgs2(e,r,t)},curry4ResolveArg0=(e,r,t,n)=>function(o){return e(o,r,t,n)},curry4ResolveArg1=(e,r,t,n)=>function(o){return e(r,o,t,n)},curry4ResolveArg2=(e,r,t,n)=>function(o){return e(r,t,o,n)},curry4ResolveArg3=(e,r,t,n)=>function(o){return e(r,t,n,o)},curry4=function(e,r,t,n,o){return r==__?curry4ResolveArg0(e,t,n,o):t==__?curry4ResolveArg1(e,r,n,o):n==__?curry4ResolveArg2(e,r,t,o):curry4ResolveArg3(e,r,t,n)},arrayReduceAsync=async function(e,r,t,n){const o=e.length;for(;++n<o;)t=r(t,e[n],n,e),isPromise(t)&&(t=await t);return t},arrayReduce=function(e,r,t){const n=e.length;let o=-1;for(void 0===t&&(t=e[++o]);++o<n;)if(t=r(t,e[o],o,e),isPromise(t))return t.then(curry4(arrayReduceAsync,e,r,__,o));return t},curry5ResolveArg0=(e,r,t,n,o)=>function(c){return e(c,r,t,n,o)},curry5ResolveArg1=(e,r,t,n,o)=>function(c){return e(r,c,t,n,o)},curry5ResolveArg2=(e,r,t,n,o)=>function(c){return e(r,t,c,n,o)},curry5ResolveArg3=(e,r,t,n,o)=>function(c){return e(r,t,n,c,o)},curry5ResolveArg4=(e,r,t,n,o)=>function(c){return e(r,t,n,o,c)},curry5=function(e,r,t,n,o,c){return r==__?curry5ResolveArg0(e,t,n,o,c):t==__?curry5ResolveArg1(e,r,n,o,c):n==__?curry5ResolveArg2(e,r,t,o,c):o==__?curry5ResolveArg3(e,r,t,n,c):curry5ResolveArg4(e,r,t,n,o)},objectKeys=Object.keys,objectReduceAsync=async function(e,r,t,n,o){const c=n.length;for(;++o<c;){const c=n[o];t=r(t,e[c],c,e),isPromise(t)&&(t=await t)}return t},objectReduce=function(e,r,t){const n=objectKeys(e),o=n.length;let c=-1;for(void 0===t&&(t=e[n[++c]]);++c<o;){const o=n[c];if(t=r(t,e[o],o,e),isPromise(t))return t.then(curry5(objectReduceAsync,e,r,__,n,c))}return t},mapReduceAsync=async function(e,r,t,n){for(const[o,c]of n)t=r(t,c,o,e),isPromise(t)&&(t=await t);return t},mapReduce=function(e,r,t){const n=e.entries();if(void 0===t){const e=n.next();if(e.done)return t;t=e.value[1]}for(const[o,c]of n)if(t=r(t,c,o,e),isPromise(t))return t.then(curry4(mapReduceAsync,e,r,__,n));return t},reducerConcat=(e,r)=>function(t,n){const o=e(t,n);return isPromise(o)?o.then(curry2(r,__,n)):r(o,n)},genericReduce=function(e,r,t){return isArray(e)?arrayReduce(e,r,t):null==e?void 0===t?curry2(r,e,__):r(t,e):e.constructor==Map?mapReduce(e,r,t):"function"==typeof e[symbolIterator]?iteratorReduce(e[symbolIterator](),r,t):"function"==typeof e[symbolAsyncIterator]?asyncIteratorReduce(e[symbolAsyncIterator](),r,t):"function"==typeof e.reduce?e.reduce(r,t):"function"==typeof e.chain?e.chain(curry2(r,t,__)):"function"==typeof e.flatMap?e.flatMap(curry2(r,t,__)):e.constructor==Object?objectReduce(e,r,t):void 0===t?curry2(r,e,__):r(t,e)},arrayPush=function(e,r){return e.push(r),e},FlatMappingIterator=function(e,r){let t=[],n=0;return{[symbolIterator](){return this},next(){if(n<t.length){const e=t[n];return n+=1,{value:e,done:!1}}const o=e.next();if(o.done)return o;const c=genericReduce(r(o.value),arrayPush,[]);return c.length>1&&(t=c,n=1),{value:c[0],done:!1}}}},promiseRace=Promise.race.bind(Promise),sleep=e=>new Promise((r=>{setTimeout(r,e)})),FlatMappingAsyncIterator=function(e,r){const t=[],n=new Set;return{isAsyncIteratorDone:!1,[symbolAsyncIterator](){return this},toString:()=>"[object FlatMappingAsyncIterator]",async next(){for(;!this.isAsyncIteratorDone||t.length>0||n.size>0;){if(!this.isAsyncIteratorDone){const{value:o,done:c}=await e.next();if(c)this.isAsyncIteratorDone=c;else{const e=r(o);if(isPromise(e)){const r=e.then(curry3(genericReduce,__,arrayPush,t)).then((()=>n.delete(r)));n.add(r)}else{const r=genericReduce(e,arrayPush,t);if(isPromise(r)){const e=r.then((()=>n.delete(e)));n.add(e)}}}}if(t.length>0)return{value:t.shift(),done:!1};n.size>0&&await promiseRace([sleep(1e3),...n])}return{value:void 0,done:!0}}}},always=e=>function(){return e},getArg1=(e,r)=>r,identity=e=>e,promiseAll=Promise.all.bind(Promise),funcConcatSync=(e,r)=>function(...t){return r(e(...t))},asyncIteratorForEach=async function(e,r){const t=[];for await(const n of e){const e=r(n);isPromise(e)&&t.push(e)}return 0==t.length?e:promiseAll(t).then(always(e))},arrayFlatten=function(e){const r=e.length,t=[],n=[];let o=-1;for(;++o<r;){const r=e[o];if(isArray(r)){const e=r.length;let t=-1;for(;++t<e;)n.push(r[t])}else if(null==r)n.push(r);else if("function"==typeof r.then)t.push(r.then(curry2(arrayPush,n,__)));else if("function"==typeof r[symbolIterator])for(const e of r)n.push(e);else if("function"==typeof r[symbolAsyncIterator])t.push(asyncIteratorForEach(r[symbolAsyncIterator](),curry2(arrayPush,n,__)));else if("function"==typeof r.chain){const e=r.chain(identity);isPromise(e)?t.push(e.then(curry2(arrayPush,n,__))):n.push(e)}else if("function"==typeof r.flatMap){const e=r.flatMap(identity);isPromise(e)?t.push(e.then(curry2(arrayPush,n,__))):n.push(e)}else if("function"==typeof r.reduce){const e=r.reduce(funcConcatSync(getArg1,curry2(arrayPush,n,__)),null);isPromise(e)&&t.push(e)}else if(r.constructor==Object)for(const e in r)n.push(r[e]);else n.push(r)}return 0==t.length?n:promiseAll(t).then(always(n))},arrayMap=function(e,r){const t=e.length,n=Array(t);let o=-1,c=!1;for(;++o<t;){const t=r(e[o],o,e);isPromise(t)&&(c=!0),n[o]=t}return c?promiseAll(n):n},arrayFlatMap=function(e,r){const t=arrayMap(e,r);return isPromise(t)?t.then(arrayFlatten):arrayFlatten(t)},promiseObjectAllExecutor=e=>function(r){const t={};let n=0;for(const o in e){const c=e[o];isPromise(c)?(n+=1,c.then((e=>function(o){t[e]=o,n-=1,0==n&&r(t)})(o))):t[o]=c}0==n&&r(t)},promiseObjectAll=e=>new Promise(promiseObjectAllExecutor(e)),objectMap=function(e,r){const t={};let n=!1;for(const o in e){const c=r(e[o],o,e);isPromise(c)&&(n=!0),t[o]=c}return n?promiseObjectAll(t):t},objectAssign=Object.assign,objectFlatten=function(e){const r=[],t={},n=curry2(objectAssign,t,__),o=funcConcatSync(getArg1,n);for(const c in e){const s=e[c];if(null!=s)if("function"==typeof s[symbolIterator])for(const e of s)objectAssign(t,e);else if("function"==typeof s[symbolAsyncIterator])r.push(asyncIteratorForEach(s[symbolAsyncIterator](),n));else if("function"==typeof s.chain){const e=s.chain(identity);isPromise(e)?r.push(e.then(n)):objectAssign(t,e)}else if("function"==typeof s.flatMap){const e=s.flatMap(identity);isPromise(e)?r.push(e.then(n)):n(e)}else if("function"==typeof s.reduce){const e=s.reduce(o,null);isPromise(e)&&r.push(e)}else objectAssign(t,s)}return 0==r.length?t:promiseAll(r).then((()=>t))},objectFlatMap=function(e,r){const t=objectMap(e,r);return isPromise(t)?t.then(objectFlatten):objectFlatten(t)},callPropUnary=(e,r,t)=>e[r](t),setMap=function(e,r){const t=new Set,n=[];for(const o of e){const c=r(o,o,e);isPromise(c)?n.push(c.then(curry3(callPropUnary,t,"add",__))):t.add(c)}return 0==n.length?t:promiseAll(n).then(always(t))},setFlatten=function(e){e.size;const r=[],t=new Set,n=(e,r)=>t.add(r),o=curry3(callPropUnary,t,"add",__);for(const c of e)if(isArray(c)){const e=c.length;let r=-1;for(;++r<e;)t.add(c[r])}else if(null==c)t.add(c);else if("function"==typeof c[symbolIterator])for(const e of c)t.add(e);else if("function"==typeof c[symbolAsyncIterator])r.push(asyncIteratorForEach(c[symbolAsyncIterator](),o));else if("function"==typeof c.chain){const e=c.chain(identity);isPromise(e)?r.push(e.then(o)):t.add(e)}else if("function"==typeof c.flatMap){const e=c.flatMap(identity);isPromise(e)?r.push(e.then(o)):t.add(e)}else if("function"==typeof c.reduce){const e=c.reduce(n,null);isPromise(e)&&r.push(e)}else if(c.constructor==Object)for(const e in c)t.add(c[e]);else t.add(c);return 0==r.length?t:promiseAll(r).then((()=>t))},setFlatMap=function(e,r){const t=setMap(e,r);return isPromise(t)?t.then(setFlatten):setFlatten(t)},funcConcat=(e,r)=>function(...t){const n=e(...t);return isPromise(n)?n.then(r):r(n)},arrayJoin=(e,r)=>e.join(r),arrayFlattenToString=funcConcat(arrayFlatten,curry2(arrayJoin,__,"")),stringFlatMap=function(e,r){const t=arrayMap(e,r);return isPromise(t)?t.then(arrayFlattenToString):arrayFlattenToString(t)},_flatMap=function(e,r){if(isArray(e))return arrayFlatMap(e,r);if(null==e)return r(e);if("function"==typeof e.then)return e.then(r);if("function"==typeof e.next)return symbolIterator in e?FlatMappingIterator(e,r):FlatMappingAsyncIterator(e,r);if("function"==typeof e.chain)return e.chain(r);if("function"==typeof e.flatMap)return e.flatMap(r);const t=e.constructor;return t==Object?objectFlatMap(e,r):t==Set?setFlatMap(e,r):"string"==typeof e||t==String?stringFlatMap(e,r):r(e)},flatMap=(e,r)=>"function"==typeof e?curry2(_flatMap,__,e):isPromise(e)?e.then(curry2(_flatMap,__,r)):_flatMap(e,r);export default flatMap;
|
package/dist/flatMap.js
CHANGED
package/dist/flatMap.min.js
CHANGED
package/dist/flatMap.mjs
CHANGED
package/dist/forEach.es.js
CHANGED
package/dist/forEach.es.min.js
CHANGED
package/dist/forEach.js
CHANGED
package/dist/forEach.min.js
CHANGED
package/dist/forEach.mjs
CHANGED
package/dist/get.es.js
CHANGED
package/dist/get.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
|
-
const isPromise=r=>null!=r&&"function"==typeof r.then,__=Symbol.for("placeholder"),curry3ResolveArg0=(r,e,t)=>function(n){return r(n,e,t)},curry3ResolveArg1=(r,e,t)=>function(n){return r(e,n,t)},curry3ResolveArg2=(r,e,t)=>function(n){return r(e,t,n)},curry3=function(r,e,t,n){return e==__?curry3ResolveArg0(r,t,n):t==__?curry3ResolveArg1(r,e,n):curry3ResolveArg2(r,e,t)},isArray=Array.isArray,isObject=r=>{if(null==r)return!1;const e=typeof r;return"object"==e||"function"==e},memoizeCappedUnary=function(r,e){const t=new Map,n=function(n){if(t.has(n))return t.get(n);const o=r(n);return t.set(n,o),t.size>e&&t.clear(),o};return n.cache=t,n},pathDelimiters=/[.|[|\]]+/,parsePropertyPath=function(r){const e=r.length-1,t="["==r[0],n="]"==r[e];return t&&n?r.slice(1,e).split(pathDelimiters):t?r.slice(1).split(pathDelimiters):n?r.slice(0,e).split(pathDelimiters):r.split(pathDelimiters)},memoizedCappedParsePropertyPath=memoizeCappedUnary(parsePropertyPath,500),propertyPathToArray=r=>isArray(r)?r:"string"==typeof r?memoizedCappedParsePropertyPath(r):[r],getByPath=function(r,e){const t=propertyPathToArray(e),n=t.length;let o=-1,i=r;for(;++o<n;)if(i=i[t[o]],null==i)return;return i},_get=function(r,e,t){const n=null==r?void 0:getByPath(r,e);return void 0===n?"function"==typeof t?t(r):t:n},get=function(r,e,t){return"string"==typeof r||"number"==typeof r||isArray(r)?curry3(_get,__,r,e):
|
|
7
|
+
const isPromise=r=>null!=r&&"function"==typeof r.then,__=Symbol.for("placeholder"),curry3ResolveArg0=(r,e,t)=>function(n){return r(n,e,t)},curry3ResolveArg1=(r,e,t)=>function(n){return r(e,n,t)},curry3ResolveArg2=(r,e,t)=>function(n){return r(e,t,n)},curry3=function(r,e,t,n){return e==__?curry3ResolveArg0(r,t,n):t==__?curry3ResolveArg1(r,e,n):curry3ResolveArg2(r,e,t)},isArray=Array.isArray,isObject=r=>{if(null==r)return!1;const e=typeof r;return"object"==e||"function"==e},memoizeCappedUnary=function(r,e){const t=new Map,n=function(n){if(t.has(n))return t.get(n);const o=r(n);return t.set(n,o),t.size>e&&t.clear(),o};return n.cache=t,n},pathDelimiters=/[.|[|\]]+/,parsePropertyPath=function(r){const e=r.length-1,t="["==r[0],n="]"==r[e];return t&&n?r.slice(1,e).split(pathDelimiters):t?r.slice(1).split(pathDelimiters):n?r.slice(0,e).split(pathDelimiters):r.split(pathDelimiters)},memoizedCappedParsePropertyPath=memoizeCappedUnary(parsePropertyPath,500),propertyPathToArray=r=>isArray(r)?r:"string"==typeof r?memoizedCappedParsePropertyPath(r):[r],getByPath=function(r,e){const t=propertyPathToArray(e),n=t.length;let o=-1,i=r;for(;++o<n;)if(i=i[t[o]],null==i)return;return i},_get=function(r,e,t){const n=null==r?void 0:getByPath(r,e);return void 0===n?"function"==typeof t?t(r):t:n},get=function(r,e,t){return"string"==typeof r||"number"==typeof r||isArray(r)?curry3(_get,__,r,e):isPromise(r)?r.then(curry3(_get,__,e,t)):_get(r,e,t)};export default get;
|
package/dist/get.js
CHANGED
package/dist/get.min.js
CHANGED
package/dist/get.mjs
CHANGED
package/dist/gt.es.js
CHANGED
package/dist/gt.es.min.js
CHANGED
package/dist/gt.js
CHANGED
package/dist/gt.min.js
CHANGED
package/dist/gt.mjs
CHANGED
package/dist/gte.es.js
CHANGED
package/dist/gte.es.min.js
CHANGED
package/dist/gte.js
CHANGED
package/dist/gte.min.js
CHANGED
package/dist/gte.mjs
CHANGED
package/dist/lt.es.js
CHANGED
package/dist/lt.es.min.js
CHANGED
package/dist/lt.js
CHANGED
package/dist/lt.min.js
CHANGED
package/dist/lt.mjs
CHANGED
package/dist/lte.es.js
CHANGED
package/dist/lte.es.min.js
CHANGED
package/dist/lte.js
CHANGED
package/dist/lte.min.js
CHANGED
package/dist/lte.mjs
CHANGED
package/dist/map.es.js
CHANGED
package/dist/map.es.min.js
CHANGED
package/dist/map.js
CHANGED
package/dist/map.min.js
CHANGED
package/dist/map.mjs
CHANGED
package/dist/not.es.js
CHANGED
package/dist/not.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
|
-
const isPromise=r=>null!=r&&"function"==typeof r.then,areAnyValuesPromises=function(r){const e=r.length;let n=-1;for(;++n<e;){const e=r[n];if(isPromise(e))return!0}return!1},promiseAll=Promise.all.bind(Promise),__=Symbol.for("placeholder"),curry2ResolveArg0=(r,e)=>function(n){return r(n,e)},curry2ResolveArg1=(r,e)=>function(n){return r(e,n)},curry2=function(r,e,n){return e==__?curry2ResolveArg0(r,n):curry2ResolveArg1(r,e)},curryArgs2ResolveArgs0=(r,e,n)=>function(...n){return r(n,e)},curryArgs2ResolveArgs1=(r,e,n)=>function(...n){return r(e,n)},curryArgs2=function(r,e,n){return e==__?curryArgs2ResolveArgs0(r,n):curryArgs2ResolveArgs1(r,e)},negate=r=>!r,_not=function(r,e){const n=e(...r);return isPromise(n)?n.then(negate):!n},not=function(...r){const e=r.pop();return"function"==typeof e?0==r.length?(
|
|
7
|
+
const isPromise=r=>null!=r&&"function"==typeof r.then,areAnyValuesPromises=function(r){const e=r.length;let n=-1;for(;++n<e;){const e=r[n];if(isPromise(e))return!0}return!1},promiseAll=Promise.all.bind(Promise),__=Symbol.for("placeholder"),curry2ResolveArg0=(r,e)=>function(n){return r(n,e)},curry2ResolveArg1=(r,e)=>function(n){return r(e,n)},curry2=function(r,e,n){return e==__?curry2ResolveArg0(r,n):curry2ResolveArg1(r,e)},curryArgs2ResolveArgs0=(r,e,n)=>function(...n){return r(n,e)},curryArgs2ResolveArgs1=(r,e,n)=>function(...n){return r(e,n)},curryArgs2=function(r,e,n){return e==__?curryArgs2ResolveArgs0(r,n):curryArgs2ResolveArgs1(r,e)},negate=r=>!r,_not=function(r,e){const n=e(...r);return isPromise(n)?n.then(negate):!n},not=function(...r){const e=r.pop();return"function"==typeof e?0==r.length?curryArgs2(_not,__,e):areAnyValuesPromises(r)?promiseAll(r).then(curry2(_not,__,e)):_not(r,e):!e};export default not;
|
package/dist/not.js
CHANGED
package/dist/not.min.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
!function(n,t){"object"==typeof module?module.exports=t:"function"==typeof define?define((()=>t)):n.not=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=n=>null!=n&&"function"==typeof n.then,t=Promise.all.bind(Promise),o=Symbol.for("placeholder"),e=n=>!n,r=function(t,o){const r=o(...t);return n(r)?r.then(e):!r};return function(...e){const u=e.pop();return"function"==typeof u?0==e.length?(f=r,c=u,(i=o)==o?((n,t
|
|
8
|
+
!function(n,t){"object"==typeof module?module.exports=t:"function"==typeof define?define((()=>t)):n.not=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=n=>null!=n&&"function"==typeof n.then,t=Promise.all.bind(Promise),o=Symbol.for("placeholder"),e=n=>!n,r=function(t,o){const r=o(...t);return n(r)?r.then(e):!r};return function(...e){const u=e.pop();return"function"==typeof u?0==e.length?(f=r,c=u,(i=o)==o?((n,t)=>function(...o){return n(o,t)})(f,c):((n,t)=>function(...o){return n(t,o)})(f,i)):function(t){const o=t.length;let e=-1;for(;++e<o;){const o=t[e];if(n(o))return!0}return!1}(e)?t(e).then(function(n,t,e){return t==o?((n,t)=>function(o){return n(o,t)})(n,e):((n,t)=>function(o){return n(t,o)})(n,t)}(r,o,u)):r(e,u):!u;var f,i,c}}());
|
package/dist/not.mjs
CHANGED
package/dist/omit.es.js
CHANGED
package/dist/omit.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
|
-
const isPromise=
|
|
7
|
+
const isPromise=e=>null!=e&&"function"==typeof e.then,isArray=Array.isArray,memoizeCappedUnary=function(e,r){const t=new Map,o=function(o){if(t.has(o))return t.get(o);const n=e(o);return t.set(o,n),t.size>r&&t.clear(),n};return o.cache=t,o},pathDelimiters=/[.|[|\]]+/,parsePropertyPath=function(e){const r=e.length-1,t="["==e[0],o="]"==e[r];return t&&o?e.slice(1,r).split(pathDelimiters):t?e.slice(1).split(pathDelimiters):o?e.slice(0,r).split(pathDelimiters):e.split(pathDelimiters)},memoizedCappedParsePropertyPath=memoizeCappedUnary(parsePropertyPath,500),propertyPathToArray=e=>isArray(e)?e:"string"==typeof e?memoizedCappedParsePropertyPath(e):[e],getByPath=function(e,r){const t=propertyPathToArray(r),o=t.length;let n=-1,i=e;for(;++n<o;)if(i=i[t[n]],null==i)return;return i},deleteByPath=function(e,r){if(null==e)return;const t=propertyPathToArray(r),o=t.length-1;let n=-1,i=e;for(;++n<o;)if(i=i[t[n]],null==i)return;const c=t[n];null!=i&&c in i&&delete i[c]},objectCopyDeep=function(e){const r={};for(const t in e){const o=e[t];isArray(o)?r[t]=arrayCopyDeep(o):null!=o&&o.constructor==Object?r[t]=objectCopyDeep(o):r[t]=o}return r},arrayCopyDeep=function(e){const r=e.length,t=[];let o=-1;for(;++o<r;){const r=e[o];isArray(r)?t[o]=arrayCopyDeep(r):null!=r&&r.constructor==Object?t[o]=objectCopyDeep(r):t[o]=r}return t},copyDeep=function(e){return isArray(e)?arrayCopyDeep(e):null==e?e:e.constructor==Object?objectCopyDeep(e):e},__=Symbol.for("placeholder"),curry2ResolveArg0=(e,r)=>function(t){return e(t,r)},curry2ResolveArg1=(e,r)=>function(t){return e(r,t)},curry2=function(e,r,t){return r==__?curry2ResolveArg0(e,t):curry2ResolveArg1(e,r)},_omit=function(e,r){const t=r.length,o=copyDeep(e);let n=-1;for(;++n<t;)deleteByPath(o,r[n]);return o},omit=function(e,r){return null==r?curry2(_omit,__,e):isPromise(e)?e.then(curry2(_omit,__,r)):_omit(e,r)};export default omit;
|
package/dist/omit.js
CHANGED
package/dist/omit.min.js
CHANGED
package/dist/omit.mjs
CHANGED
package/dist/or.es.js
CHANGED
package/dist/or.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
|
-
const promiseAll=Promise.all.bind(Promise),isPromise=r=>null!=r&&"function"==typeof r.then,areAnyValuesPromises=function(r){const n=r.length;let e=-1;for(;++e<n;){const n=r[e];if(isPromise(n))return!0}return!1},__=Symbol.for("placeholder"),curry2ResolveArg0=(r,n)=>function(e){return r(e,n)},curry2ResolveArg1=(r,n)=>function(e){return r(n,e)},curry2=function(r,n,e){return n==__?curry2ResolveArg0(r,e):curry2ResolveArg1(r,n)},curry3ResolveArg0=(r,n,e)=>function(t){return r(t,n,e)},curry3ResolveArg1=(r,n,e)=>function(t){return r(n,t,e)},curry3ResolveArg2=(r,n,e)=>function(t){return r(n,e,t)},curry3=function(r,n,e,t){return n==__?curry3ResolveArg0(r,e,t):e==__?curry3ResolveArg1(r,n,t):curry3ResolveArg2(r,n,e)},curryArgs2ResolveArgs0=(r,n,e)=>function(...e){return r(e,n)},curryArgs2ResolveArgs1=(r,n,e)=>function(...e){return r(n,e)},curryArgs2=function(r,n,e){return n==__?curryArgs2ResolveArgs0(r,e):curryArgs2ResolveArgs1(r,n)},thunkConditional=(r,n,e)=>r?n():e(),areAllValuesNonfunctions=function(r){const n=r.length;let e=-1;for(;++e<n;)if("function"==typeof r[e])return!1;return!0},thunkify2=(r,n,e)=>function(){return r(n,e)},thunkify3=(r,n,e,t)=>function(){return r(n,e,t)},always=r=>function(){return r},areAnyNonfunctionsTruthy=function(r,n){const e=r.length;for(;++n<e;){const e=r[n];if(isPromise(e))return e.then(curry3(thunkConditional,__,always(!0),thunkify2(areAnyNonfunctionsTruthy,r,n)));if(e)return!0}return!1},asyncAreAnyPredicatesTruthy=async function(r,n,e){const t=n.length;for(;++e<t;){let t=n[e];if("function"==typeof t&&(t=t(...r)),isPromise(t)&&(t=await t),t)return!0}return!1},areAnyPredicatesTruthy=function(r,n){const e=n.length;let t=-1;for(;++t<e;){let e=n[t];if("function"==typeof e&&(e=e(...r)),isPromise(e))return e.then(curry3(thunkConditional,__,always(!0),thunkify3(asyncAreAnyPredicatesTruthy,r,n,t)));if(e)return!0}return!1},or=function(...r){const n=r.pop();return areAllValuesNonfunctions(n)?areAnyNonfunctionsTruthy(n,-1):0==r.length?(
|
|
7
|
+
const promiseAll=Promise.all.bind(Promise),isPromise=r=>null!=r&&"function"==typeof r.then,areAnyValuesPromises=function(r){const n=r.length;let e=-1;for(;++e<n;){const n=r[e];if(isPromise(n))return!0}return!1},__=Symbol.for("placeholder"),curry2ResolveArg0=(r,n)=>function(e){return r(e,n)},curry2ResolveArg1=(r,n)=>function(e){return r(n,e)},curry2=function(r,n,e){return n==__?curry2ResolveArg0(r,e):curry2ResolveArg1(r,n)},curry3ResolveArg0=(r,n,e)=>function(t){return r(t,n,e)},curry3ResolveArg1=(r,n,e)=>function(t){return r(n,t,e)},curry3ResolveArg2=(r,n,e)=>function(t){return r(n,e,t)},curry3=function(r,n,e,t){return n==__?curry3ResolveArg0(r,e,t):e==__?curry3ResolveArg1(r,n,t):curry3ResolveArg2(r,n,e)},curryArgs2ResolveArgs0=(r,n,e)=>function(...e){return r(e,n)},curryArgs2ResolveArgs1=(r,n,e)=>function(...e){return r(n,e)},curryArgs2=function(r,n,e){return n==__?curryArgs2ResolveArgs0(r,e):curryArgs2ResolveArgs1(r,n)},thunkConditional=(r,n,e)=>r?n():e(),areAllValuesNonfunctions=function(r){const n=r.length;let e=-1;for(;++e<n;)if("function"==typeof r[e])return!1;return!0},thunkify2=(r,n,e)=>function(){return r(n,e)},thunkify3=(r,n,e,t)=>function(){return r(n,e,t)},always=r=>function(){return r},areAnyNonfunctionsTruthy=function(r,n){const e=r.length;for(;++n<e;){const e=r[n];if(isPromise(e))return e.then(curry3(thunkConditional,__,always(!0),thunkify2(areAnyNonfunctionsTruthy,r,n)));if(e)return!0}return!1},asyncAreAnyPredicatesTruthy=async function(r,n,e){const t=n.length;for(;++e<t;){let t=n[e];if("function"==typeof t&&(t=t(...r)),isPromise(t)&&(t=await t),t)return!0}return!1},areAnyPredicatesTruthy=function(r,n){const e=n.length;let t=-1;for(;++t<e;){let e=n[t];if("function"==typeof e&&(e=e(...r)),isPromise(e))return e.then(curry3(thunkConditional,__,always(!0),thunkify3(asyncAreAnyPredicatesTruthy,r,n,t)));if(e)return!0}return!1},or=function(...r){const n=r.pop();return areAllValuesNonfunctions(n)?areAnyNonfunctionsTruthy(n,-1):0==r.length?curryArgs2(areAnyPredicatesTruthy,__,n):areAnyValuesPromises(r)?promiseAll(r).then(curry2(areAnyPredicatesTruthy,__,n)):areAnyPredicatesTruthy(r,n)};export default or;
|
package/dist/or.js
CHANGED
package/dist/or.min.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
!function(n,t){"object"==typeof module?module.exports=t:"function"==typeof define?define((()=>t)):n.or=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=Promise.all.bind(Promise),t=n=>null!=n&&"function"==typeof n.then,r=Symbol.for("placeholder"),e=function(n,t,e,o){return t==r?((n,t,r)=>function(e){return n(e,t,r)})(n,e,o):e==r?((n,t,r)=>function(e){return n(t,e,r)})(n,t,o):((n,t,r)=>function(e){return n(t,r,e)})(n,t,e)},o=(n,t,r)=>n?t():r(),u=(n,t,r)=>function(){return n(t,r)},f=(n,t,r,e)=>function(){return n(t,r,e)},i=n=>function(){return n},c=function(n,f){const l=n.length;for(;++f<l;){const l=n[f];if(t(l))return l.then(e(o,r,i(!0),u(c,n,f)));if(l)return!0}return!1},l=async function(n,r,e){const o=r.length;for(;++e<o;){let o=r[e];if("function"==typeof o&&(o=o(...n)),t(o)&&(o=await o),o)return!0}return!1},s=function(n,u){const c=u.length;let s=-1;for(;++s<c;){let c=u[s];if("function"==typeof c&&(c=c(...n)),t(c))return c.then(e(o,r,i(!0),f(l,n,u,s)));if(c)return!0}return!1};return function(...e){const o=e.pop();return function(n){const t=n.length;let r=-1;for(;++r<t;)if("function"==typeof n[r])return!1;return!0}(o)?c(o,-1):0==e.length?(u=s,i=o,(f=r)==r?((n,t
|
|
8
|
+
!function(n,t){"object"==typeof module?module.exports=t:"function"==typeof define?define((()=>t)):n.or=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=Promise.all.bind(Promise),t=n=>null!=n&&"function"==typeof n.then,r=Symbol.for("placeholder"),e=function(n,t,e,o){return t==r?((n,t,r)=>function(e){return n(e,t,r)})(n,e,o):e==r?((n,t,r)=>function(e){return n(t,e,r)})(n,t,o):((n,t,r)=>function(e){return n(t,r,e)})(n,t,e)},o=(n,t,r)=>n?t():r(),u=(n,t,r)=>function(){return n(t,r)},f=(n,t,r,e)=>function(){return n(t,r,e)},i=n=>function(){return n},c=function(n,f){const l=n.length;for(;++f<l;){const l=n[f];if(t(l))return l.then(e(o,r,i(!0),u(c,n,f)));if(l)return!0}return!1},l=async function(n,r,e){const o=r.length;for(;++e<o;){let o=r[e];if("function"==typeof o&&(o=o(...n)),t(o)&&(o=await o),o)return!0}return!1},s=function(n,u){const c=u.length;let s=-1;for(;++s<c;){let c=u[s];if("function"==typeof c&&(c=c(...n)),t(c))return c.then(e(o,r,i(!0),f(l,n,u,s)));if(c)return!0}return!1};return function(...e){const o=e.pop();return function(n){const t=n.length;let r=-1;for(;++r<t;)if("function"==typeof n[r])return!1;return!0}(o)?c(o,-1):0==e.length?(u=s,i=o,(f=r)==r?((n,t)=>function(...r){return n(r,t)})(u,i):((n,t)=>function(...r){return n(t,r)})(u,f)):function(n){const r=n.length;let e=-1;for(;++e<r;){const r=n[e];if(t(r))return!0}return!1}(e)?n(e).then(function(n,t,e){return t==r?((n,t)=>function(r){return n(r,t)})(n,e):((n,t)=>function(r){return n(t,r)})(n,t)}(s,r,o)):s(e,o);var u,f,i}}());
|
package/dist/or.mjs
CHANGED
package/dist/pick.es.js
CHANGED
package/dist/pick.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.4.
|
|
2
|
+
* rubico v2.4.2
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2024 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
6
6
|
*/
|
|
7
|
-
const isPromise=r=>null!=r&&"function"==typeof r.then,isArray=Array.isArray,memoizeCappedUnary=function(r,t){const e=new Map,n=function(n){if(e.has(n))return e.get(n);const i=r(n);return e.set(n,i),e.size>t&&e.clear(),i};return n.cache=e,n},pathDelimiters=/[.|[|\]]+/,parsePropertyPath=function(r){const t=r.length-1,e="["==r[0],n="]"==r[t];return e&&n?r.slice(1,t).split(pathDelimiters):e?r.slice(1).split(pathDelimiters):n?r.slice(0,t).split(pathDelimiters):r.split(pathDelimiters)},memoizedCappedParsePropertyPath=memoizeCappedUnary(parsePropertyPath,500),propertyPathToArray=r=>isArray(r)?r:"string"==typeof r?memoizedCappedParsePropertyPath(r):[r],getByPath=function(r,t){const e=propertyPathToArray(t),n=e.length;let i=-1,o=r;for(;++i<n;)if(o=o[e[i]],null==o)return;return o},isObject=r=>{if(null==r)return!1;const t=typeof r;return"object"==t||"function"==t},setByPath=function(r,t,e){if(!isObject(r))return r;const n=propertyPathToArray(e),i=n.length,o=i-1,
|
|
7
|
+
const isPromise=r=>null!=r&&"function"==typeof r.then,isArray=Array.isArray,memoizeCappedUnary=function(r,t){const e=new Map,n=function(n){if(e.has(n))return e.get(n);const i=r(n);return e.set(n,i),e.size>t&&e.clear(),i};return n.cache=e,n},pathDelimiters=/[.|[|\]]+/,parsePropertyPath=function(r){const t=r.length-1,e="["==r[0],n="]"==r[t];return e&&n?r.slice(1,t).split(pathDelimiters):e?r.slice(1).split(pathDelimiters):n?r.slice(0,t).split(pathDelimiters):r.split(pathDelimiters)},memoizedCappedParsePropertyPath=memoizeCappedUnary(parsePropertyPath,500),propertyPathToArray=r=>isArray(r)?r:"string"==typeof r?memoizedCappedParsePropertyPath(r):[r],getByPath=function(r,t){const e=propertyPathToArray(t),n=e.length;let i=-1,o=r;for(;++i<n;)if(o=o[e[i]],null==o)return;return o},isObject=r=>{if(null==r)return!1;const t=typeof r;return"object"==t||"function"==t},setByPath=function(r,t,e){if(!isObject(r))return r;const n=propertyPathToArray(e),i=n.length,o=i-1,s={...r};let c=s,l=-1;for(;++l<i;){const r=n[l];if(l==o)c[r]=t;else{const t=c[r],e=isArray(t)?t.slice():{...t};c[r]=e,c=e}}return s},__=Symbol.for("placeholder"),curry2ResolveArg0=(r,t)=>function(e){return r(e,t)},curry2ResolveArg1=(r,t)=>function(e){return r(t,e)},curry2=function(r,t,e){return t==__?curry2ResolveArg0(r,e):curry2ResolveArg1(r,t)},_pick=function(r,t){if(null==r)return r;const e=t.length;let n={},i=-1;for(;++i<e;){const e=t[i],o=getByPath(r,e);null!=o&&(n=setByPath(n,o,e))}return n},pick=function(r,t){return null==t?curry2(_pick,__,r):isPromise(r)?r.then(curry2(_pick,__,t)):_pick(r,t)};export default pick;
|
package/dist/pick.js
CHANGED
package/dist/pick.min.js
CHANGED
package/dist/pick.mjs
CHANGED
package/dist/pipe.es.js
CHANGED