rubico 2.1.0 → 2.2.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.
- package/README.md +2 -0
- package/_internal/genericTransform.js +30 -28
- package/dist/Transducer.es.js +1 -1
- package/dist/Transducer.es.min.js +1 -1
- 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 +1 -1
- package/dist/all.js +1 -1
- package/dist/all.min.js +1 -1
- 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 +1 -1
- package/dist/and.js +1 -1
- package/dist/and.min.js +1 -1
- package/dist/and.mjs +1 -1
- package/dist/assign.es.js +1 -1
- package/dist/assign.es.min.js +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- package/dist/not.js +1 -1
- package/dist/not.min.js +1 -1
- package/dist/not.mjs +1 -1
- package/dist/omit.es.js +1 -1
- package/dist/omit.es.min.js +1 -1
- 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 +1 -1
- package/dist/or.js +1 -1
- package/dist/or.min.js +1 -1
- package/dist/or.mjs +1 -1
- package/dist/pick.es.js +1 -1
- package/dist/pick.es.min.js +1 -1
- 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 +1 -1
- 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 +1 -1
- package/dist/reduce.js +1 -1
- package/dist/reduce.min.js +1 -1
- package/dist/reduce.mjs +1 -1
- package/dist/rubico.es.js +57 -46
- package/dist/rubico.es.min.js +2 -2
- package/dist/rubico.global.js +57 -46
- package/dist/rubico.global.min.js +2 -2
- package/dist/rubico.js +57 -46
- package/dist/rubico.min.js +2 -2
- package/dist/rubico.mjs +57 -46
- 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 +1 -1
- package/dist/switchCase.js +1 -1
- package/dist/switchCase.min.js +1 -1
- package/dist/switchCase.mjs +1 -1
- package/dist/tap.es.js +32 -2
- package/dist/tap.es.min.js +2 -2
- package/dist/tap.js +32 -2
- package/dist/tap.min.js +2 -2
- package/dist/tap.mjs +32 -2
- package/dist/thunkify.es.js +1 -1
- package/dist/thunkify.es.min.js +1 -1
- package/dist/thunkify.js +1 -1
- package/dist/thunkify.min.js +1 -1
- package/dist/thunkify.mjs +1 -1
- package/dist/transform.es.js +26 -24
- package/dist/transform.es.min.js +2 -2
- package/dist/transform.js +26 -24
- package/dist/transform.min.js +2 -2
- package/dist/transform.mjs +26 -24
- 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 +1 -1
- 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 +1 -1
- package/dist/x/filterOut.js +1 -1
- package/dist/x/filterOut.min.js +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +1 -1
- 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 +32 -2
- package/dist/x/trace.es.min.js +2 -2
- package/dist/x/trace.js +32 -2
- package/dist/x/trace.min.js +2 -2
- package/dist/x/trace.mjs +32 -2
- 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 +1 -1
- 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 +1 -1
- 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 +57 -46
- package/index.js +57 -46
- package/package.json +43 -2
- package/tap.js +15 -4
- package/.eslintignore +0 -5
- package/.eslintrc.js +0 -330
- package/.github/workflows/nodejs.yml +0 -27
- package/.vscode/launch.json +0 -25
- package/AggregateReducer.test.js +0 -82
- package/CHANGELOG.md +0 -310
- package/CNAME +0 -1
- package/CODE_OF_CONDUCT.md +0 -128
- package/CONTRIBUTING.md +0 -4
- package/Transducer.test.js +0 -154
- package/_config.yml +0 -1
- package/_internal/improvedGenericTransform.js +0 -93
- package/archive/FlatMappingIterator-2020-09-28.js +0 -68
- package/archive/_Promise-2023-05-29.js +0 -93
- package/archive/arrayMap2-2023-05-29.js +0 -73
- package/archive/benchmarks-v1.9.7/all.js +0 -34
- package/archive/benchmarks-v1.9.7/and.js +0 -24
- package/archive/benchmarks-v1.9.7/any.js +0 -32
- package/archive/benchmarks-v1.9.7/assign.js +0 -174
- package/archive/benchmarks-v1.9.7/curry.js +0 -55
- package/archive/benchmarks-v1.9.7/eq.js +0 -25
- package/archive/benchmarks-v1.9.7/filter.js +0 -1322
- package/archive/benchmarks-v1.9.7/flatMap.js +0 -48
- package/archive/benchmarks-v1.9.7/forEach.js +0 -33
- package/archive/benchmarks-v1.9.7/fork.js +0 -123
- package/archive/benchmarks-v1.9.7/get.js +0 -44
- package/archive/benchmarks-v1.9.7/gt.js +0 -25
- package/archive/benchmarks-v1.9.7/gte.js +0 -25
- package/archive/benchmarks-v1.9.7/integration.js +0 -88
- package/archive/benchmarks-v1.9.7/lt.js +0 -25
- package/archive/benchmarks-v1.9.7/lte.js +0 -25
- package/archive/benchmarks-v1.9.7/map.js +0 -892
- package/archive/benchmarks-v1.9.7/misc.js +0 -470
- package/archive/benchmarks-v1.9.7/omit.js +0 -28
- package/archive/benchmarks-v1.9.7/or.js +0 -51
- package/archive/benchmarks-v1.9.7/pick.js +0 -24
- package/archive/benchmarks-v1.9.7/pipe.js +0 -152
- package/archive/benchmarks-v1.9.7/reduce.js +0 -739
- package/archive/benchmarks-v1.9.7/switchCase.js +0 -256
- package/archive/benchmarks-v1.9.7/tap.js +0 -90
- package/archive/benchmarks-v1.9.7/transform.js +0 -218
- package/archive/benchmarks-v1.9.7/tryCatch.js +0 -108
- package/archive/curry.js +0 -13
- package/archive/examples-v1.6.11/browserModule.html +0 -31
- package/archive/examples-v1.6.11/browserScript.html +0 -32
- package/archive/examples-v1.6.11/coolTransformToConsole.js +0 -1
- package/archive/examples-v1.6.11/denoLargeGasMap.js +0 -85
- package/archive/examples-v1.6.11/denoServer.js +0 -9
- package/archive/examples-v1.6.11/denoServerWithMiddleware.js +0 -55
- package/archive/examples-v1.6.11/logTodosRange.js +0 -21
- package/archive/examples-v1.6.11/makeARequest.html +0 -46
- package/archive/examples-v1.6.11/nodeComplexTransformation.js +0 -106
- package/archive/examples-v1.6.11/nodeConditionallyExtractIDs.js +0 -50
- package/archive/examples-v1.6.11/nodeFloatingPoint.js +0 -55
- package/archive/examples-v1.6.11/nodeGetAllJiraBoards.js +0 -45
- package/archive/examples-v1.6.11/nodeGetSocketIOClientsTotalCount.js +0 -34
- package/archive/examples-v1.6.11/nodeKafkaConsumer.js +0 -63
- package/archive/examples-v1.6.11/nodeMakeMultipleRequests.js +0 -55
- package/archive/examples-v1.6.11/nodeOnRecordAddTask.js +0 -34
- package/archive/examples-v1.6.11/nodePostRequestWithAuth.js +0 -36
- package/archive/examples-v1.6.11/nodeSpeedbackMatchmakingAlgorithm.js +0 -96
- package/archive/examples-v1.6.11/nodeTireData.js +0 -36
- package/archive/examples-v1.6.11/nodeTripleMap.js +0 -85
- package/archive/examples-v1.6.11/squaredOdds.ts +0 -16
- package/archive/examples-v1.6.11/transducerMaxBuyer.js +0 -67
- package/archive/examples-v1.6.11/transformLogTodosRange.js +0 -31
- package/archive/examples-v1.6.11/transformStreamRandomInts.js +0 -19
- package/archive/genericReduceConcurrent.js +0 -277
- package/archive/index.v0.2.9.js +0 -1685
- package/archive/objectValuesGenerator.js +0 -13
- package/archive/test.v0.2.9.js +0 -2334
- package/bench +0 -65
- package/benchmark-output/v1.9.7 +0 -268
- package/benchmarks/all.async.js +0 -43
- package/benchmarks/all.js +0 -43
- package/benchmarks/always.js +0 -15
- package/benchmarks/and.async.js +0 -25
- package/benchmarks/and.js +0 -25
- package/benchmarks/assign.async.js +0 -27
- package/benchmarks/assign.js +0 -27
- package/benchmarks/curry.js +0 -35
- package/benchmarks/eq.async.js +0 -23
- package/benchmarks/eq.js +0 -23
- package/benchmarks/every.async.js +0 -19
- package/benchmarks/every.js +0 -19
- package/benchmarks/filter.async.js +0 -32
- package/benchmarks/filter.js +0 -38
- package/benchmarks/flatMap.async.js +0 -26
- package/benchmarks/flatMap.js +0 -38
- package/benchmarks/get.async.js +0 -19
- package/benchmarks/get.js +0 -39
- package/benchmarks/gt.async.js +0 -23
- package/benchmarks/gt.js +0 -23
- package/benchmarks/gte.async.js +0 -23
- package/benchmarks/gte.js +0 -23
- package/benchmarks/lt.async.js +0 -23
- package/benchmarks/lt.js +0 -23
- package/benchmarks/lte.async.js +0 -23
- package/benchmarks/lte.js +0 -23
- package/benchmarks/map.async.js +0 -43
- package/benchmarks/map.js +0 -40
- package/benchmarks/misc/Promise.js +0 -26
- package/benchmarks/misc/isPromise.js +0 -30
- package/benchmarks/misc/promiseAll.js +0 -36
- package/benchmarks/not.js +0 -23
- package/benchmarks/omit.js +0 -38
- package/benchmarks/or.async.js +0 -25
- package/benchmarks/or.js +0 -25
- package/benchmarks/pick.js +0 -38
- package/benchmarks/pipe.async.js +0 -47
- package/benchmarks/pipe.js +0 -47
- package/benchmarks/reduce.async.js +0 -32
- package/benchmarks/reduce.js +0 -38
- package/benchmarks/set.async.js +0 -19
- package/benchmarks/set.js +0 -41
- package/benchmarks/some.async.js +0 -19
- package/benchmarks/some.js +0 -19
- package/benchmarks/switchCase.async.js +0 -27
- package/benchmarks/switchCase.js +0 -55
- package/benchmarks/tap.js +0 -15
- package/benchmarks/thunkify.js +0 -15
- package/benchmarks/transform.async.js +0 -27
- package/benchmarks/transform.js +0 -40
- package/benchmarks/tryCatch.async.js +0 -25
- package/benchmarks/tryCatch.js +0 -32
- package/build +0 -472
- package/dist-test.js +0 -37
- package/examples/type-to-search-wiki/README.md +0 -19
- package/examples/type-to-search-wiki/package.json +0 -13
- package/examples/type-to-search-wiki/src/app.js +0 -46
- package/examples/type-to-search-wiki/src/index.html +0 -18
- package/import-test.html +0 -73
- package/memory-usage/reduce.js +0 -40
- package/monad/AsyncPool.js +0 -0
- package/monad/BrokenPromise.js +0 -63
- package/monad/BrokenPromise.test.js +0 -22
- package/monad/Cancellable.js +0 -84
- package/monad/Cancellable.memoryUsage.js +0 -60
- package/monad/Cancellable.test.js +0 -20
- package/monad/Function.js +0 -0
- package/monad/Instance.benchmark.js +0 -378
- package/monad/Instance.js +0 -351
- package/monad/Instance.test.js +0 -445
- package/monad/Mux.benchmark.js +0 -29
- package/monad/Mux.js +0 -589
- package/monad/Mux.test.js +0 -512
- package/monad/PossiblePromise.benchmark.js +0 -87
- package/monad/PossiblePromise.js +0 -144
- package/monad/PossiblePromise.test.js +0 -89
- package/monad/README.md +0 -75
- package/monad/Reducer.js +0 -0
- package/monad/Sequence.benchmark.js +0 -42
- package/monad/Sequence.js +0 -36
- package/monad/SpecScript.js +0 -0
- package/monad/Stack.js +0 -0
- package/monad/Struct.benchmark.js +0 -154
- package/monad/Struct.js +0 -249
- package/monad/Struct.test.js +0 -237
- package/rubico.js +0 -66
- package/test.js +0 -4242
- package/tmp.js +0 -1
package/dist/x/maxBy.es.min.js
CHANGED
package/dist/x/maxBy.js
CHANGED
package/dist/x/maxBy.min.js
CHANGED
package/dist/x/maxBy.mjs
CHANGED
package/dist/x/noop.es.js
CHANGED
package/dist/x/noop.es.min.js
CHANGED
package/dist/x/noop.js
CHANGED
package/dist/x/noop.min.js
CHANGED
package/dist/x/noop.mjs
CHANGED
package/dist/x/pluck.es.js
CHANGED
package/dist/x/pluck.es.min.js
CHANGED
package/dist/x/pluck.js
CHANGED
package/dist/x/pluck.min.js
CHANGED
package/dist/x/pluck.mjs
CHANGED
package/dist/x/prepend.es.js
CHANGED
package/dist/x/prepend.es.min.js
CHANGED
package/dist/x/prepend.js
CHANGED
package/dist/x/prepend.min.js
CHANGED
package/dist/x/prepend.mjs
CHANGED
package/dist/x/size.es.js
CHANGED
package/dist/x/size.es.min.js
CHANGED
package/dist/x/size.js
CHANGED
package/dist/x/size.min.js
CHANGED
package/dist/x/size.mjs
CHANGED
package/dist/x/trace.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.
|
|
2
|
+
* rubico v2.2.0
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2023 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
@@ -59,12 +59,42 @@ const curry3 = function (baseFunc, arg0, arg1, arg2) {
|
|
|
59
59
|
return curry3ResolveArg2(baseFunc, arg0, arg1)
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
|
|
62
|
+
// argument resolver for curryArgs2
|
|
63
|
+
const curryArgs2ResolveArgs0 = (
|
|
64
|
+
baseFunc, arg1, arg2,
|
|
65
|
+
) => function args0Resolver(...args) {
|
|
66
|
+
return baseFunc(args, arg1)
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
// argument resolver for curryArgs2
|
|
70
|
+
const curryArgs2ResolveArgs1 = (
|
|
71
|
+
baseFunc, arg0, arg2,
|
|
72
|
+
) => function arg1Resolver(...args) {
|
|
73
|
+
return baseFunc(arg0, args)
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
const curryArgs2 = function (baseFunc, arg0, arg1) {
|
|
77
|
+
if (arg0 == __) {
|
|
78
|
+
return curryArgs2ResolveArgs0(baseFunc, arg1)
|
|
79
|
+
}
|
|
80
|
+
return curryArgs2ResolveArgs1(baseFunc, arg0)
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// _tap(args Array, func function) -> Promise|any
|
|
84
|
+
const _tap = function (args, func) {
|
|
63
85
|
const result = args[0],
|
|
64
86
|
call = func(...args)
|
|
65
87
|
return isPromise(call) ? call.then(always(result)) : result
|
|
66
88
|
}
|
|
67
89
|
|
|
90
|
+
const tap = function (...args) {
|
|
91
|
+
const func = args.pop()
|
|
92
|
+
if (args.length == 0) {
|
|
93
|
+
return curryArgs2(_tap, __, func)
|
|
94
|
+
}
|
|
95
|
+
return _tap(args, func)
|
|
96
|
+
}
|
|
97
|
+
|
|
68
98
|
tap.if = (predicate, func) => function tappingIf(...args) {
|
|
69
99
|
const predication = predicate(...args)
|
|
70
100
|
if (isPromise(predication)) {
|
package/dist/x/trace.es.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.
|
|
2
|
+
* rubico v2.2.0
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2023 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,funcConcat=(r,n)=>function(...
|
|
7
|
+
const isPromise=r=>null!=r&&"function"==typeof r.then,funcConcat=(r,n)=>function(...e){const o=r(...e);return isPromise(o)?o.then(n):n(o)},always=r=>function(){return r},thunkifyArgs=(r,n)=>function(){return r(...n)},thunkConditional=(r,n,e)=>r?n():e(),__=Symbol.for("placeholder"),curry3ResolveArg0=(r,n,e)=>function(o){return r(o,n,e)},curry3ResolveArg1=(r,n,e)=>function(o){return r(n,o,e)},curry3ResolveArg2=(r,n,e)=>function(o){return r(n,e,o)},curry3=function(r,n,e,o){return n==__?curry3ResolveArg0(r,e,o):e==__?curry3ResolveArg1(r,n,o):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)},_tap=function(r,n){const e=r[0],o=n(...r);return isPromise(o)?o.then(always(e)):e},tap=function(...r){const n=r.pop();return 0==r.length?(e=_tap,t=n,(o=__)==__?curryArgs2ResolveArgs0(e,t):curryArgs2ResolveArgs1(e,o)):_tap(r,n);var e,o,t};tap.if=(r,n)=>function(...e){const o=r(...e);if(isPromise(o))return o.then((t=thunkConditional,s=__,u=thunkifyArgs(tap(n),e),c=always(e[0]),s==__?curry3ResolveArg0(t,u,c):u==__?curry3ResolveArg1(t,s,c):curry3ResolveArg2(t,s,u)));var t,s,u,c;if(o){const r=n(...e);if(isPromise(r))return r.then(always(e[0]))}return e[0]};const consoleLog=console.log,trace=function(...r){const n=r[0];return"function"==typeof n?tap((e=n,o=consoleLog,function(...r){const n=e(...r);return isPromise(n)?n.then(o):o(n)})):tap(consoleLog)(...r);var e,o};export default trace;
|
package/dist/x/trace.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.
|
|
2
|
+
* rubico v2.2.0
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2023 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
@@ -65,12 +65,42 @@ const curry3 = function (baseFunc, arg0, arg1, arg2) {
|
|
|
65
65
|
return curry3ResolveArg2(baseFunc, arg0, arg1)
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
|
|
68
|
+
// argument resolver for curryArgs2
|
|
69
|
+
const curryArgs2ResolveArgs0 = (
|
|
70
|
+
baseFunc, arg1, arg2,
|
|
71
|
+
) => function args0Resolver(...args) {
|
|
72
|
+
return baseFunc(args, arg1)
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
// argument resolver for curryArgs2
|
|
76
|
+
const curryArgs2ResolveArgs1 = (
|
|
77
|
+
baseFunc, arg0, arg2,
|
|
78
|
+
) => function arg1Resolver(...args) {
|
|
79
|
+
return baseFunc(arg0, args)
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
const curryArgs2 = function (baseFunc, arg0, arg1) {
|
|
83
|
+
if (arg0 == __) {
|
|
84
|
+
return curryArgs2ResolveArgs0(baseFunc, arg1)
|
|
85
|
+
}
|
|
86
|
+
return curryArgs2ResolveArgs1(baseFunc, arg0)
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
// _tap(args Array, func function) -> Promise|any
|
|
90
|
+
const _tap = function (args, func) {
|
|
69
91
|
const result = args[0],
|
|
70
92
|
call = func(...args)
|
|
71
93
|
return isPromise(call) ? call.then(always(result)) : result
|
|
72
94
|
}
|
|
73
95
|
|
|
96
|
+
const tap = function (...args) {
|
|
97
|
+
const func = args.pop()
|
|
98
|
+
if (args.length == 0) {
|
|
99
|
+
return curryArgs2(_tap, __, func)
|
|
100
|
+
}
|
|
101
|
+
return _tap(args, func)
|
|
102
|
+
}
|
|
103
|
+
|
|
74
104
|
tap.if = (predicate, func) => function tappingIf(...args) {
|
|
75
105
|
const predication = predicate(...args)
|
|
76
106
|
if (isPromise(predication)) {
|
package/dist/x/trace.min.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.
|
|
2
|
+
* rubico v2.2.0
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2023 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.trace=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=n=>null!=n&&"function"==typeof n.then,t=n=>function(){return n},o=(n,t,o)=>n?t():o(),e=Symbol.for("placeholder"),r=
|
|
8
|
+
!function(n,t){"object"==typeof module?module.exports=t:"function"==typeof define?define((()=>t)):n.trace=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=n=>null!=n&&"function"==typeof n.then,t=n=>function(){return n},o=(n,t,o)=>n?t():o(),e=Symbol.for("placeholder"),r=function(o,e){const r=o[0],u=e(...o);return n(u)?u.then(t(r)):r},u=function(...n){const t=n.pop();return 0==n.length?(o=r,c=t,(u=e)==e?((n,t,o)=>function(...o){return n(o,t)})(o,c):((n,t,o)=>function(...o){return n(t,o)})(o,u)):r(n,t);var o,u,c};u.if=(r,c)=>function(...f){const i=r(...f);if(n(i))return i.then((s=o,l=e,h=((n,t)=>function(){return n(...t)})(u(c),f),p=t(f[0]),l==e?((n,t,o)=>function(e){return n(e,t,o)})(s,h,p):h==e?((n,t,o)=>function(e){return n(t,e,o)})(s,l,p):((n,t,o)=>function(e){return n(t,o,e)})(s,l,h)));var s,l,h,p;if(i){const o=c(...f);if(n(o))return o.then(t(f[0]))}return f[0]};const c=console.log;return function(...t){const o=t[0];return"function"==typeof o?u((e=o,r=c,function(...t){const o=e(...t);return n(o)?o.then(r):r(o)})):u(c)(...t);var e,r}}());
|
package/dist/x/trace.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* rubico v2.
|
|
2
|
+
* rubico v2.2.0
|
|
3
3
|
* https://github.com/a-synchronous/rubico
|
|
4
4
|
* (c) 2019-2023 Richard Tong
|
|
5
5
|
* rubico may be freely distributed under the MIT license.
|
|
@@ -59,12 +59,42 @@ const curry3 = function (baseFunc, arg0, arg1, arg2) {
|
|
|
59
59
|
return curry3ResolveArg2(baseFunc, arg0, arg1)
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
|
|
62
|
+
// argument resolver for curryArgs2
|
|
63
|
+
const curryArgs2ResolveArgs0 = (
|
|
64
|
+
baseFunc, arg1, arg2,
|
|
65
|
+
) => function args0Resolver(...args) {
|
|
66
|
+
return baseFunc(args, arg1)
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
// argument resolver for curryArgs2
|
|
70
|
+
const curryArgs2ResolveArgs1 = (
|
|
71
|
+
baseFunc, arg0, arg2,
|
|
72
|
+
) => function arg1Resolver(...args) {
|
|
73
|
+
return baseFunc(arg0, args)
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
const curryArgs2 = function (baseFunc, arg0, arg1) {
|
|
77
|
+
if (arg0 == __) {
|
|
78
|
+
return curryArgs2ResolveArgs0(baseFunc, arg1)
|
|
79
|
+
}
|
|
80
|
+
return curryArgs2ResolveArgs1(baseFunc, arg0)
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// _tap(args Array, func function) -> Promise|any
|
|
84
|
+
const _tap = function (args, func) {
|
|
63
85
|
const result = args[0],
|
|
64
86
|
call = func(...args)
|
|
65
87
|
return isPromise(call) ? call.then(always(result)) : result
|
|
66
88
|
}
|
|
67
89
|
|
|
90
|
+
const tap = function (...args) {
|
|
91
|
+
const func = args.pop()
|
|
92
|
+
if (args.length == 0) {
|
|
93
|
+
return curryArgs2(_tap, __, func)
|
|
94
|
+
}
|
|
95
|
+
return _tap(args, func)
|
|
96
|
+
}
|
|
97
|
+
|
|
68
98
|
tap.if = (predicate, func) => function tappingIf(...args) {
|
|
69
99
|
const predication = predicate(...args)
|
|
70
100
|
if (isPromise(predication)) {
|
package/dist/x/unionWith.es.js
CHANGED
package/dist/x/unionWith.js
CHANGED
package/dist/x/unionWith.min.js
CHANGED
package/dist/x/unionWith.mjs
CHANGED
package/dist/x/uniq.es.js
CHANGED
package/dist/x/uniq.es.min.js
CHANGED
package/dist/x/uniq.js
CHANGED
package/dist/x/uniq.min.js
CHANGED
package/dist/x/uniq.mjs
CHANGED
package/dist/x/unless.es.js
CHANGED
package/dist/x/unless.es.min.js
CHANGED
package/dist/x/unless.js
CHANGED
package/dist/x/unless.min.js
CHANGED
package/dist/x/unless.mjs
CHANGED
package/dist/x/values.es.js
CHANGED
package/dist/x/values.es.min.js
CHANGED
package/dist/x/values.js
CHANGED
package/dist/x/values.min.js
CHANGED
package/dist/x/values.mjs
CHANGED
package/dist/x/when.es.js
CHANGED
package/dist/x/when.es.min.js
CHANGED
package/dist/x/when.js
CHANGED
package/dist/x/when.min.js
CHANGED
package/dist/x/when.mjs
CHANGED