rubico 2.4.0 → 2.4.1

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 (340) hide show
  1. package/dist/Transducer.es.js +1 -1
  2. package/dist/Transducer.es.min.js +1 -1
  3. package/dist/Transducer.js +1 -1
  4. package/dist/Transducer.min.js +1 -1
  5. package/dist/Transducer.mjs +1 -1
  6. package/dist/__.es.js +1 -1
  7. package/dist/__.es.min.js +1 -1
  8. package/dist/__.js +1 -1
  9. package/dist/__.min.js +1 -1
  10. package/dist/__.mjs +1 -1
  11. package/dist/all.es.js +1 -1
  12. package/dist/all.es.min.js +1 -1
  13. package/dist/all.js +1 -1
  14. package/dist/all.min.js +1 -1
  15. package/dist/all.mjs +1 -1
  16. package/dist/always.es.js +1 -1
  17. package/dist/always.es.min.js +1 -1
  18. package/dist/always.js +1 -1
  19. package/dist/always.min.js +1 -1
  20. package/dist/always.mjs +1 -1
  21. package/dist/and.es.js +1 -1
  22. package/dist/and.es.min.js +1 -1
  23. package/dist/and.js +1 -1
  24. package/dist/and.min.js +1 -1
  25. package/dist/and.mjs +1 -1
  26. package/dist/assign.es.js +1 -1
  27. package/dist/assign.es.min.js +1 -1
  28. package/dist/assign.js +1 -1
  29. package/dist/assign.min.js +1 -1
  30. package/dist/assign.mjs +1 -1
  31. package/dist/compose.es.js +1 -1
  32. package/dist/compose.es.min.js +1 -1
  33. package/dist/compose.js +1 -1
  34. package/dist/compose.min.js +1 -1
  35. package/dist/compose.mjs +1 -1
  36. package/dist/curry.es.js +1 -1
  37. package/dist/curry.es.min.js +1 -1
  38. package/dist/curry.js +1 -1
  39. package/dist/curry.min.js +1 -1
  40. package/dist/curry.mjs +1 -1
  41. package/dist/eq.es.js +1 -1
  42. package/dist/eq.es.min.js +1 -1
  43. package/dist/eq.js +1 -1
  44. package/dist/eq.min.js +1 -1
  45. package/dist/eq.mjs +1 -1
  46. package/dist/every.es.js +7 -12
  47. package/dist/every.es.min.js +2 -2
  48. package/dist/every.js +7 -12
  49. package/dist/every.min.js +2 -2
  50. package/dist/every.mjs +7 -12
  51. package/dist/filter.es.js +5 -6
  52. package/dist/filter.es.min.js +2 -2
  53. package/dist/filter.js +5 -6
  54. package/dist/filter.min.js +2 -2
  55. package/dist/filter.mjs +5 -6
  56. package/dist/flatMap.es.js +7 -9
  57. package/dist/flatMap.es.min.js +2 -2
  58. package/dist/flatMap.js +7 -9
  59. package/dist/flatMap.min.js +2 -2
  60. package/dist/flatMap.mjs +7 -9
  61. package/dist/forEach.es.js +1 -1
  62. package/dist/forEach.es.min.js +1 -1
  63. package/dist/forEach.js +1 -1
  64. package/dist/forEach.min.js +1 -1
  65. package/dist/forEach.mjs +1 -1
  66. package/dist/get.es.js +1 -1
  67. package/dist/get.es.min.js +1 -1
  68. package/dist/get.js +1 -1
  69. package/dist/get.min.js +1 -1
  70. package/dist/get.mjs +1 -1
  71. package/dist/gt.es.js +1 -1
  72. package/dist/gt.es.min.js +1 -1
  73. package/dist/gt.js +1 -1
  74. package/dist/gt.min.js +1 -1
  75. package/dist/gt.mjs +1 -1
  76. package/dist/gte.es.js +1 -1
  77. package/dist/gte.es.min.js +1 -1
  78. package/dist/gte.js +1 -1
  79. package/dist/gte.min.js +1 -1
  80. package/dist/gte.mjs +1 -1
  81. package/dist/lt.es.js +1 -1
  82. package/dist/lt.es.min.js +1 -1
  83. package/dist/lt.js +1 -1
  84. package/dist/lt.min.js +1 -1
  85. package/dist/lt.mjs +1 -1
  86. package/dist/lte.es.js +1 -1
  87. package/dist/lte.es.min.js +1 -1
  88. package/dist/lte.js +1 -1
  89. package/dist/lte.min.js +1 -1
  90. package/dist/lte.mjs +1 -1
  91. package/dist/map.es.js +13 -21
  92. package/dist/map.es.min.js +2 -2
  93. package/dist/map.js +13 -21
  94. package/dist/map.min.js +2 -2
  95. package/dist/map.mjs +13 -21
  96. package/dist/not.es.js +1 -1
  97. package/dist/not.es.min.js +1 -1
  98. package/dist/not.js +1 -1
  99. package/dist/not.min.js +1 -1
  100. package/dist/not.mjs +1 -1
  101. package/dist/omit.es.js +1 -1
  102. package/dist/omit.es.min.js +1 -1
  103. package/dist/omit.js +1 -1
  104. package/dist/omit.min.js +1 -1
  105. package/dist/omit.mjs +1 -1
  106. package/dist/or.es.js +1 -1
  107. package/dist/or.es.min.js +1 -1
  108. package/dist/or.js +1 -1
  109. package/dist/or.min.js +1 -1
  110. package/dist/or.mjs +1 -1
  111. package/dist/pick.es.js +1 -1
  112. package/dist/pick.es.min.js +1 -1
  113. package/dist/pick.js +1 -1
  114. package/dist/pick.min.js +1 -1
  115. package/dist/pick.mjs +1 -1
  116. package/dist/pipe.es.js +1 -1
  117. package/dist/pipe.es.min.js +1 -1
  118. package/dist/pipe.js +1 -1
  119. package/dist/pipe.min.js +1 -1
  120. package/dist/pipe.mjs +1 -1
  121. package/dist/reduce.es.js +1 -1
  122. package/dist/reduce.es.min.js +1 -1
  123. package/dist/reduce.js +1 -1
  124. package/dist/reduce.min.js +1 -1
  125. package/dist/reduce.mjs +1 -1
  126. package/dist/rubico.es.js +35 -56
  127. package/dist/rubico.es.min.js +2 -2
  128. package/dist/rubico.global.js +35 -56
  129. package/dist/rubico.global.min.js +2 -2
  130. package/dist/rubico.js +35 -56
  131. package/dist/rubico.min.js +2 -2
  132. package/dist/rubico.mjs +35 -56
  133. package/dist/set.es.js +1 -1
  134. package/dist/set.es.min.js +1 -1
  135. package/dist/set.js +1 -1
  136. package/dist/set.min.js +1 -1
  137. package/dist/set.mjs +1 -1
  138. package/dist/some.es.js +7 -12
  139. package/dist/some.es.min.js +2 -2
  140. package/dist/some.js +7 -12
  141. package/dist/some.min.js +2 -2
  142. package/dist/some.mjs +7 -12
  143. package/dist/switchCase.es.js +1 -1
  144. package/dist/switchCase.es.min.js +1 -1
  145. package/dist/switchCase.js +1 -1
  146. package/dist/switchCase.min.js +1 -1
  147. package/dist/switchCase.mjs +1 -1
  148. package/dist/tap.es.js +1 -1
  149. package/dist/tap.es.min.js +1 -1
  150. package/dist/tap.js +1 -1
  151. package/dist/tap.min.js +1 -1
  152. package/dist/tap.mjs +1 -1
  153. package/dist/thunkify.es.js +1 -1
  154. package/dist/thunkify.es.min.js +1 -1
  155. package/dist/thunkify.js +1 -1
  156. package/dist/thunkify.min.js +1 -1
  157. package/dist/thunkify.mjs +1 -1
  158. package/dist/transform.es.js +1 -1
  159. package/dist/transform.es.min.js +1 -1
  160. package/dist/transform.js +1 -1
  161. package/dist/transform.min.js +1 -1
  162. package/dist/transform.mjs +1 -1
  163. package/dist/tryCatch.es.js +1 -1
  164. package/dist/tryCatch.es.min.js +1 -1
  165. package/dist/tryCatch.js +1 -1
  166. package/dist/tryCatch.min.js +1 -1
  167. package/dist/tryCatch.mjs +1 -1
  168. package/dist/x/append.es.js +1 -1
  169. package/dist/x/append.es.min.js +1 -1
  170. package/dist/x/append.js +1 -1
  171. package/dist/x/append.min.js +1 -1
  172. package/dist/x/append.mjs +1 -1
  173. package/dist/x/callProp.es.js +1 -1
  174. package/dist/x/callProp.es.min.js +1 -1
  175. package/dist/x/callProp.js +1 -1
  176. package/dist/x/callProp.min.js +1 -1
  177. package/dist/x/callProp.mjs +1 -1
  178. package/dist/x/defaultsDeep.es.js +1 -1
  179. package/dist/x/defaultsDeep.es.min.js +1 -1
  180. package/dist/x/defaultsDeep.js +1 -1
  181. package/dist/x/defaultsDeep.min.js +1 -1
  182. package/dist/x/defaultsDeep.mjs +1 -1
  183. package/dist/x/differenceWith.es.js +1 -1
  184. package/dist/x/differenceWith.es.min.js +1 -1
  185. package/dist/x/differenceWith.js +1 -1
  186. package/dist/x/differenceWith.min.js +1 -1
  187. package/dist/x/differenceWith.mjs +1 -1
  188. package/dist/x/filterOut.es.js +5 -6
  189. package/dist/x/filterOut.es.min.js +2 -2
  190. package/dist/x/filterOut.js +5 -6
  191. package/dist/x/filterOut.min.js +2 -2
  192. package/dist/x/filterOut.mjs +5 -6
  193. package/dist/x/find.es.js +1 -1
  194. package/dist/x/find.es.min.js +1 -1
  195. package/dist/x/find.js +1 -1
  196. package/dist/x/find.min.js +1 -1
  197. package/dist/x/find.mjs +1 -1
  198. package/dist/x/findIndex.es.js +1 -1
  199. package/dist/x/findIndex.es.min.js +1 -1
  200. package/dist/x/findIndex.js +1 -1
  201. package/dist/x/findIndex.min.js +1 -1
  202. package/dist/x/findIndex.mjs +1 -1
  203. package/dist/x/first.es.js +1 -1
  204. package/dist/x/first.es.min.js +1 -1
  205. package/dist/x/first.js +1 -1
  206. package/dist/x/first.min.js +1 -1
  207. package/dist/x/first.mjs +1 -1
  208. package/dist/x/flatten.es.js +7 -9
  209. package/dist/x/flatten.es.min.js +2 -2
  210. package/dist/x/flatten.js +7 -9
  211. package/dist/x/flatten.min.js +2 -2
  212. package/dist/x/flatten.mjs +7 -9
  213. package/dist/x/groupBy.es.js +1 -1
  214. package/dist/x/groupBy.es.min.js +1 -1
  215. package/dist/x/groupBy.js +1 -1
  216. package/dist/x/groupBy.min.js +1 -1
  217. package/dist/x/groupBy.mjs +1 -1
  218. package/dist/x/has.es.js +1 -1
  219. package/dist/x/has.es.min.js +1 -1
  220. package/dist/x/has.js +1 -1
  221. package/dist/x/has.min.js +1 -1
  222. package/dist/x/has.mjs +1 -1
  223. package/dist/x/identity.es.js +1 -1
  224. package/dist/x/identity.es.min.js +1 -1
  225. package/dist/x/identity.js +1 -1
  226. package/dist/x/identity.min.js +1 -1
  227. package/dist/x/identity.mjs +1 -1
  228. package/dist/x/includes.es.js +1 -1
  229. package/dist/x/includes.es.min.js +1 -1
  230. package/dist/x/includes.js +1 -1
  231. package/dist/x/includes.min.js +1 -1
  232. package/dist/x/includes.mjs +1 -1
  233. package/dist/x/isDeepEqual.es.js +1 -1
  234. package/dist/x/isDeepEqual.es.min.js +1 -1
  235. package/dist/x/isDeepEqual.js +1 -1
  236. package/dist/x/isDeepEqual.min.js +1 -1
  237. package/dist/x/isDeepEqual.mjs +1 -1
  238. package/dist/x/isEmpty.es.js +1 -1
  239. package/dist/x/isEmpty.es.min.js +1 -1
  240. package/dist/x/isEmpty.js +1 -1
  241. package/dist/x/isEmpty.min.js +1 -1
  242. package/dist/x/isEmpty.mjs +1 -1
  243. package/dist/x/isEqual.es.js +1 -1
  244. package/dist/x/isEqual.es.min.js +1 -1
  245. package/dist/x/isEqual.js +1 -1
  246. package/dist/x/isEqual.min.js +1 -1
  247. package/dist/x/isEqual.mjs +1 -1
  248. package/dist/x/isFunction.es.js +1 -1
  249. package/dist/x/isFunction.es.min.js +1 -1
  250. package/dist/x/isFunction.js +1 -1
  251. package/dist/x/isFunction.min.js +1 -1
  252. package/dist/x/isFunction.mjs +1 -1
  253. package/dist/x/isIn.es.js +1 -1
  254. package/dist/x/isIn.es.min.js +1 -1
  255. package/dist/x/isIn.js +1 -1
  256. package/dist/x/isIn.min.js +1 -1
  257. package/dist/x/isIn.mjs +1 -1
  258. package/dist/x/isObject.es.js +1 -1
  259. package/dist/x/isObject.es.min.js +1 -1
  260. package/dist/x/isObject.js +1 -1
  261. package/dist/x/isObject.min.js +1 -1
  262. package/dist/x/isObject.mjs +1 -1
  263. package/dist/x/isString.es.js +1 -1
  264. package/dist/x/isString.es.min.js +1 -1
  265. package/dist/x/isString.js +1 -1
  266. package/dist/x/isString.min.js +1 -1
  267. package/dist/x/isString.mjs +1 -1
  268. package/dist/x/keys.es.js +1 -1
  269. package/dist/x/keys.es.min.js +1 -1
  270. package/dist/x/keys.js +1 -1
  271. package/dist/x/keys.min.js +1 -1
  272. package/dist/x/keys.mjs +1 -1
  273. package/dist/x/last.es.js +1 -1
  274. package/dist/x/last.es.min.js +1 -1
  275. package/dist/x/last.js +1 -1
  276. package/dist/x/last.min.js +1 -1
  277. package/dist/x/last.mjs +1 -1
  278. package/dist/x/maxBy.es.js +1 -1
  279. package/dist/x/maxBy.es.min.js +1 -1
  280. package/dist/x/maxBy.js +1 -1
  281. package/dist/x/maxBy.min.js +1 -1
  282. package/dist/x/maxBy.mjs +1 -1
  283. package/dist/x/noop.es.js +1 -1
  284. package/dist/x/noop.es.min.js +1 -1
  285. package/dist/x/noop.js +1 -1
  286. package/dist/x/noop.min.js +1 -1
  287. package/dist/x/noop.mjs +1 -1
  288. package/dist/x/pluck.es.js +13 -21
  289. package/dist/x/pluck.es.min.js +2 -2
  290. package/dist/x/pluck.js +13 -21
  291. package/dist/x/pluck.min.js +2 -2
  292. package/dist/x/pluck.mjs +13 -21
  293. package/dist/x/prepend.es.js +1 -1
  294. package/dist/x/prepend.es.min.js +1 -1
  295. package/dist/x/prepend.js +1 -1
  296. package/dist/x/prepend.min.js +1 -1
  297. package/dist/x/prepend.mjs +1 -1
  298. package/dist/x/size.es.js +1 -1
  299. package/dist/x/size.es.min.js +1 -1
  300. package/dist/x/size.js +1 -1
  301. package/dist/x/size.min.js +1 -1
  302. package/dist/x/size.mjs +1 -1
  303. package/dist/x/trace.es.js +1 -1
  304. package/dist/x/trace.es.min.js +1 -1
  305. package/dist/x/trace.js +1 -1
  306. package/dist/x/trace.min.js +1 -1
  307. package/dist/x/trace.mjs +1 -1
  308. package/dist/x/unionWith.es.js +1 -1
  309. package/dist/x/unionWith.es.min.js +1 -1
  310. package/dist/x/unionWith.js +1 -1
  311. package/dist/x/unionWith.min.js +1 -1
  312. package/dist/x/unionWith.mjs +1 -1
  313. package/dist/x/uniq.es.js +1 -1
  314. package/dist/x/uniq.es.min.js +1 -1
  315. package/dist/x/uniq.js +1 -1
  316. package/dist/x/uniq.min.js +1 -1
  317. package/dist/x/uniq.mjs +1 -1
  318. package/dist/x/unless.es.js +1 -1
  319. package/dist/x/unless.es.min.js +1 -1
  320. package/dist/x/unless.js +1 -1
  321. package/dist/x/unless.min.js +1 -1
  322. package/dist/x/unless.mjs +1 -1
  323. package/dist/x/values.es.js +1 -1
  324. package/dist/x/values.es.min.js +1 -1
  325. package/dist/x/values.js +1 -1
  326. package/dist/x/values.min.js +1 -1
  327. package/dist/x/values.mjs +1 -1
  328. package/dist/x/when.es.js +1 -1
  329. package/dist/x/when.es.min.js +1 -1
  330. package/dist/x/when.js +1 -1
  331. package/dist/x/when.min.js +1 -1
  332. package/dist/x/when.mjs +1 -1
  333. package/es.js +35 -56
  334. package/every.js +6 -11
  335. package/filter.js +4 -6
  336. package/flatMap.js +6 -8
  337. package/index.js +35 -56
  338. package/map.js +12 -21
  339. package/package.json +1 -1
  340. package/some.js +6 -12
package/dist/map.min.js CHANGED
@@ -1,8 +1,8 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.map=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=n=>null!=n&&"function"==typeof n.then,t=Symbol.iterator,r=(n,r)=>({toString:()=>"[object MappingIterator]",[t](){return this},next(){const t=n.next();return t.done?t:{value:r(t.value),done:!1}}}),e=n=>({value:n,done:!1}),o=Symbol.asyncIterator,u=(t,r)=>({[o](){return this},async next(){const o=await t.next();if(o.done)return o;const u=r(o.value);return n(u)?u.then(e):{value:u,done:!1}}}),c=Symbol.for("placeholder"),i=function(n,t,r){return t==c?((n,t)=>function(r){return n(r,t)})(n,r):((n,t)=>function(r){return n(t,r)})(n,t)},f=Array.isArray,s=Promise.all.bind(Promise),h=function(t,r){const e=t.length,o=Array(e);let u=-1,c=!1;for(;++u<e;){const e=r(t[u],u,t);n(e)&&(c=!0),o[u]=e}return c?s(o):o},l=function(n,t,r,e){return t==c?((n,t,r)=>function(e){return n(e,t,r)})(n,r,e):r==c?((n,t,r)=>function(e){return n(t,e,r)})(n,t,e):((n,t,r)=>function(e){return n(t,r,e)})(n,t,r)},a=(n,t,r)=>n[t](r),p=n=>function(){return n},y=function(n,t,r,e,o){return t==c?((n,t,r,e)=>function(o){return n(o,t,r,e)})(n,r,e,o):r==c?((n,t,r,e)=>function(o){return n(t,o,r,e)})(n,t,e,o):e==c?((n,t,r,e)=>function(o){return n(t,r,o,e)})(n,t,r,o):((n,t,r,e)=>function(o){return n(t,r,e,o)})(n,t,r,e)},d=(n,t,r,e)=>n[t](r,e),g=t=>new Promise((t=>function(r){const e={};let o=0;for(const u in t){const c=t[u];n(c)?(o+=1,c.then((n=>function(t){e[n]=t,o-=1,0==o&&r(e)})(u))):e[u]=c}0==o&&r(e)})(t)),w=(t,r)=>function(...e){const o=t(...e);return n(o)?o.then(r):r(o)},b=function(n,t,r){return n[t]=r,n},m=async function(t,r,e,o){const u=t.length;for(;++o<u;){const u=r(t[o],o);e[o]=n(u)?await u:u}return e},j=n=>function(...t){return n(...t),t[0]},S=Promise.race.bind(Promise),v=async function(t,r,e,o,u,c){const i=t.length;for(;++u<i;){c.size>=e&&await S(c);const i=r(t[u]);if(n(i)){const n=i.then(j((()=>c.delete(n))));c.add(n),o[u]=n}else o[u]=i}return s(o)},A=(n,t,r)=>function(...e){const o=r.length,u=e.length,i=[];let f=-1,s=-1,h=0;for(;++f<o;){const o=r[f];if(o==c&&(s+=1)<u){const n=e[s];n==c&&(h+=1),i.push(n)}else i.push(o);if(i.length==n)return 0==h?t(...i):M(n,t,i)}for(;++s<u;){const r=e[s];if(r==c&&(h+=1),i.push(r),i.length==n)return 0==h?t(...i):M(n,t,i)}return M(n,t,i)},M=function(n,t,r){const e=r.length;if(e<n)return A(n,t,r);let o=-1;for(;++o<e;){if(r[o]==c)return A(n,t,r)}return t(...r)},T=n=>function([t,r]){return n(t,r)},x=function(n,t,r){return n.set(t,r)},E=function(t,r){const e=new Map,o=[];return t.forEach(((t,r,e)=>function(o,u){const c=t([u,o]);n(c)?e.push(c.then(T(M(3,x,[r])))):r.set(c[0],c[1])})(r,e,o)),0==o.length?e:s(o).then(p(e))},P=function(e,i){return f(e)?h(e,i):null==e?e:"function"==typeof e.then?e.then(i):"function"==typeof e.map?e.map(i):"string"==typeof e||e.constructor==String?function(t,r){const e=h(t,r);return n(e)?e.then(l(a,c,"join","")):e.join("")}(e,i):e.constructor==Set?function(t,r){const e=new Set,o=[];for(const u of t){const i=r(u,u,t);n(i)?o.push(i.then(l(a,e,"add",c))):e.add(i)}return 0==o.length?e:s(o).then(p(e))}(e,i):e.constructor==Map?function(t,r){const e=new Map,o=[];for(const[u,i]of t){const f=r(i,u,t);n(f)?o.push(f.then(y(d,e,"set",u,c))):e.set(u,f)}return 0==o.length?e:s(o).then(p(e))}(e,i):"function"==typeof e[t]?r(e[t](),i):"function"==typeof e[o]?u(e[o](),i):e.constructor==Object?function(t,r){const e={};let o=!1;for(const u in t){const c=r(t[u],u,t);n(c)&&(o=!0),e[u]=c}return o?g(e):e}(e,i):i(e)},O=(...t)=>{const r=t.pop();if(0==t.length)return i(P,c,r);const e=t[0];return n(e)?e.then(i(P,c,r)):P(e,r)},I=(t,r)=>{if(null==t)throw new TypeError("value is not an Object or Map");if(t.constructor==Object)return function(t,r){const e={},o=[];for(const u in t){const c=r([u,t[u]]);n(c)?o.push(c.then(T(M(3,b,[e])))):e[c[0]]=c[1]}return 0==o.length?e:s(o).then(p(e))}(t,r);if(t.constructor==Map)return E(t,r);throw new TypeError("value is not an Object or Map")};return O.entries=function(...t){const r=t.pop();if(0==t.length)return i(I,c,r);const e=t[0];return n(e)?e.then(i(I,c,r)):I(e,r)},O.series=t=>function(r){if(f(r))return function(t,r){const e=t.length,o=Array(e);let u=-1;for(;++u<e;){const e=r(t[u],u);if(n(e))return e.then(w(l(b,o,u,c),y(m,t,r,c,u)));o[u]=e}return o}(r,t);throw new TypeError(`${r} is not an Array`)},O.pool=(t,r)=>function(e){if(f(e))return function(t,r,e){const o=t.length,u=Array(o);let c=-1;for(;++c<o;){const o=r(t[c]);if(n(o)){const n=new Set,i=o.then(j((()=>n.delete(i))));return n.add(i),u[c]=i,v(t,r,e,u,c,n)}u[c]=o}return u}(e,r,t);throw new TypeError(`${e} is not an Array`)},O}());
8
+ !function(n,t){"object"==typeof module?module.exports=t:"function"==typeof define?define((()=>t)):n.map=t}("object"==typeof globalThis?globalThis:this,function(){"use strict";const n=n=>null!=n&&"function"==typeof n.then,t=Symbol.iterator,e=(n,e)=>({toString:()=>"[object MappingIterator]",[t](){return this},next(){const t=n.next();return t.done?t:{value:e(t.value),done:!1}}}),r=n=>({value:n,done:!1}),o=Symbol.asyncIterator,u=(t,e)=>({[o](){return this},async next(){const o=await t.next();if(o.done)return o;const u=e(o.value);return n(u)?u.then(r):{value:u,done:!1}}}),c=Symbol.for("placeholder"),i=function(n,t,e){return t==c?((n,t)=>function(e){return n(e,t)})(n,e):((n,t)=>function(e){return n(t,e)})(n,t)},f=Array.isArray,s=Promise.all.bind(Promise),h=function(t,e){const r=t.length,o=Array(r);let u=-1,c=!1;for(;++u<r;){const r=e(t[u],u,t);n(r)&&(c=!0),o[u]=r}return c?s(o):o},l=function(n,t,e,r){return t==c?((n,t,e)=>function(r){return n(r,t,e)})(n,e,r):e==c?((n,t,e)=>function(r){return n(t,r,e)})(n,t,r):((n,t,e)=>function(r){return n(t,e,r)})(n,t,e)},a=(n,t,e)=>n[t](e),p=n=>function(){return n},y=function(n,t,e,r,o){return t==c?((n,t,e,r)=>function(o){return n(o,t,e,r)})(n,e,r,o):e==c?((n,t,e,r)=>function(o){return n(t,o,e,r)})(n,t,r,o):r==c?((n,t,e,r)=>function(o){return n(t,e,o,r)})(n,t,e,o):((n,t,e,r)=>function(o){return n(t,e,r,o)})(n,t,e,r)},d=(n,t,e,r)=>n[t](e,r),g=t=>new Promise((t=>function(e){const r={};let o=0;for(const u in t){const c=t[u];n(c)?(o+=1,c.then((n=>function(t){r[n]=t,o-=1,0==o&&e(r)})(u))):r[u]=c}0==o&&e(r)})(t)),w=(t,e)=>function(...r){const o=t(...r);return n(o)?o.then(e):e(o)},b=function(n,t,e){return n[t]=e,n},m=async function(t,e,r,o){const u=t.length;for(;++o<u;){const u=e(t[o],o);r[o]=n(u)?await u:u}return r},j=n=>function(...t){return n(...t),t[0]},S=Promise.race.bind(Promise),v=async function(t,e,r,o,u,c){const i=t.length;for(;++u<i;){c.size>=r&&await S(c);const i=e(t[u]);if(n(i)){const n=i.then(j((()=>c.delete(n))));c.add(n),o[u]=n}else o[u]=i}return s(o)},A=(n,t,e)=>function(...r){const o=e.length,u=r.length,i=[];let f=-1,s=-1,h=0;for(;++f<o;){const o=e[f];if(o==c&&(s+=1)<u){const n=r[s];n==c&&(h+=1),i.push(n)}else i.push(o);if(i.length==n)return 0==h?t(...i):M(n,t,i)}for(;++s<u;){const e=r[s];if(e==c&&(h+=1),i.push(e),i.length==n)return 0==h?t(...i):M(n,t,i)}return M(n,t,i)},M=function(n,t,e){const r=e.length;if(r<n)return A(n,t,e);let o=-1;for(;++o<r;){if(e[o]==c)return A(n,t,e)}return t(...e)},T=n=>function([t,e]){return n(t,e)},x=function(n,t,e){return n.set(t,e)},E=function(t,e){const r=new Map,o=[];return t.forEach(((t,e,r)=>function(o,u){const c=t([u,o]);n(c)?r.push(c.then(T(M(3,x,[e])))):e.set(c[0],c[1])})(e,r,o)),0==o.length?r:s(o).then(p(r))},P=function(r,i){return f(r)?h(r,i):null==r?r:"function"==typeof r.then?r.then(i):"function"==typeof r.map?r.map(i):"string"==typeof r||r.constructor==String?function(t,e){const r=h(t,e);return n(r)?r.then(l(a,c,"join","")):r.join("")}(r,i):r.constructor==Set?function(t,e){const r=new Set,o=[];for(const u of t){const i=e(u,u,t);n(i)?o.push(i.then(l(a,r,"add",c))):r.add(i)}return 0==o.length?r:s(o).then(p(r))}(r,i):r.constructor==Map?function(t,e){const r=new Map,o=[];for(const[u,i]of t){const f=e(i,u,t);n(f)?o.push(f.then(y(d,r,"set",u,c))):r.set(u,f)}return 0==o.length?r:s(o).then(p(r))}(r,i):"function"==typeof r[t]?e(r[t](),i):"function"==typeof r[o]?u(r[o](),i):r.constructor==Object?function(t,e){const r={};let o=!1;for(const u in t){const c=e(t[u],u,t);n(c)&&(o=!0),r[u]=c}return o?g(r):r}(r,i):i(r)},O=function(t,e){return"function"==typeof t?i(P,c,t):n(t)?t.then(i(P,c,e)):P(t,e)},I=(t,e)=>{if(null==t)throw new TypeError("value is not an Object or Map");if(t.constructor==Object)return function(t,e){const r={},o=[];for(const u in t){const c=e([u,t[u]]);n(c)?o.push(c.then(T(M(3,b,[r])))):r[c[0]]=c[1]}return 0==o.length?r:s(o).then(p(r))}(t,e);if(t.constructor==Map)return E(t,e);throw new TypeError("value is not an Object or Map")};return O.entries=function(t,e){return"function"==typeof t?i(I,c,t):n(t)?t.then(i(I,c,e)):I(t,e)},O.series=t=>function(e){if(f(e))return function(t,e){const r=t.length,o=Array(r);let u=-1;for(;++u<r;){const r=e(t[u],u);if(n(r))return r.then(w(l(b,o,u,c),y(m,t,e,c,u)));o[u]=r}return o}(e,t);throw new TypeError(`${e} is not an Array`)},O.pool=(t,e)=>function(r){if(f(r))return function(t,e,r){const o=t.length,u=Array(o);let c=-1;for(;++c<o;){const o=e(t[c]);if(n(o)){const n=new Set,i=o.then(j((()=>n.delete(i))));return n.add(i),u[c]=i,v(t,e,r,u,c,n)}u[c]=o}return u}(r,e,t);throw new TypeError(`${r} is not an Array`)},O}());
package/dist/map.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -480,17 +480,13 @@ const _map = function (value, mapper) {
480
480
  return mapper(value)
481
481
  }
482
482
 
483
- const map = (...args) => {
484
- const mapper = args.pop()
485
- if (args.length == 0) {
486
- return curry2(_map, __, mapper)
483
+ const map = function (arg0, arg1) {
484
+ if (typeof arg0 == 'function') {
485
+ return curry2(_map, __, arg0)
487
486
  }
488
-
489
- const collection = args[0]
490
- if (isPromise(collection)) {
491
- return collection.then(curry2(_map, __, mapper))
492
- }
493
- return _map(collection, mapper)
487
+ return isPromise(arg0)
488
+ ? arg0.then(curry2(_map, __, arg1))
489
+ : _map(arg0, arg1)
494
490
  }
495
491
 
496
492
  // _mapEntries(value Object|Map, mapper function) -> Object|Map
@@ -507,17 +503,13 @@ const _mapEntries = (value, mapper) => {
507
503
  throw new TypeError('value is not an Object or Map')
508
504
  }
509
505
 
510
- map.entries = function mapEntries(...args) {
511
- const mapper = args.pop()
512
- if (args.length == 0) {
513
- return curry2(_mapEntries, __, mapper)
514
- }
515
-
516
- const collection = args[0]
517
- if (isPromise(collection)) {
518
- return collection.then(curry2(_mapEntries, __, mapper))
506
+ map.entries = function mapEntries(arg0, arg1) {
507
+ if (typeof arg0 == 'function') {
508
+ return curry2(_mapEntries, __, arg0)
519
509
  }
520
- return _mapEntries(collection, mapper)
510
+ return isPromise(arg0)
511
+ ? arg0.then(curry2(_mapEntries, __, arg1))
512
+ : _mapEntries(arg0, arg1)
521
513
  }
522
514
 
523
515
  map.series = mapper => function mappingInSeries(value) {
package/dist/not.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/not.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/not.min.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/not.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/omit.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/omit.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/omit.min.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/omit.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/or.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/or.es.min.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/or.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/or.min.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/or.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pick.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pick.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pick.min.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pick.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pipe.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pipe.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pipe.min.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/pipe.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/reduce.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/reduce.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/reduce.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
package/dist/rubico.es.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * rubico v2.4.0
2
+ * rubico v2.4.1
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.
@@ -846,17 +846,13 @@ const _map = function (value, mapper) {
846
846
  return mapper(value)
847
847
  }
848
848
 
849
- const map = (...args) => {
850
- const mapper = args.pop()
851
- if (args.length == 0) {
852
- return curry2(_map, __, mapper)
853
- }
854
-
855
- const collection = args[0]
856
- if (isPromise(collection)) {
857
- return collection.then(curry2(_map, __, mapper))
849
+ const map = function (arg0, arg1) {
850
+ if (typeof arg0 == 'function') {
851
+ return curry2(_map, __, arg0)
858
852
  }
859
- return _map(collection, mapper)
853
+ return isPromise(arg0)
854
+ ? arg0.then(curry2(_map, __, arg1))
855
+ : _map(arg0, arg1)
860
856
  }
861
857
 
862
858
  // _mapEntries(value Object|Map, mapper function) -> Object|Map
@@ -873,17 +869,13 @@ const _mapEntries = (value, mapper) => {
873
869
  throw new TypeError('value is not an Object or Map')
874
870
  }
875
871
 
876
- map.entries = function mapEntries(...args) {
877
- const mapper = args.pop()
878
- if (args.length == 0) {
879
- return curry2(_mapEntries, __, mapper)
880
- }
881
-
882
- const collection = args[0]
883
- if (isPromise(collection)) {
884
- return collection.then(curry2(_mapEntries, __, mapper))
872
+ map.entries = function mapEntries(arg0, arg1) {
873
+ if (typeof arg0 == 'function') {
874
+ return curry2(_mapEntries, __, arg0)
885
875
  }
886
- return _mapEntries(collection, mapper)
876
+ return isPromise(arg0)
877
+ ? arg0.then(curry2(_mapEntries, __, arg1))
878
+ : _mapEntries(arg0, arg1)
887
879
  }
888
880
 
889
881
  map.series = mapper => function mappingInSeries(value) {
@@ -1093,12 +1085,11 @@ const _filter = function (value, predicate) {
1093
1085
  return value
1094
1086
  }
1095
1087
 
1096
- const filter = function (...args) {
1097
- const predicate = args.pop()
1098
- if (args.length == 0) {
1099
- return curry2(_filter, __, predicate)
1088
+ const filter = function (arg0, arg1) {
1089
+ if (typeof arg0 == 'function') {
1090
+ return curry2(_filter, __, arg0)
1100
1091
  }
1101
- return _filter(args[0], predicate)
1092
+ return _filter(arg0, arg1)
1102
1093
  }
1103
1094
 
1104
1095
  const objectValues = Object.values
@@ -1856,15 +1847,13 @@ const _flatMap = function (value, flatMapper) {
1856
1847
  return flatMapper(value)
1857
1848
  }
1858
1849
 
1859
- const flatMap = (...args) => {
1860
- const flatMapper = args.pop()
1861
- if (args.length == 0) {
1862
- return curry2(_flatMap, __, flatMapper)
1850
+ const flatMap = (arg0, arg1) => {
1851
+ if (typeof arg0 == 'function') {
1852
+ return curry2(_flatMap, __, arg0)
1863
1853
  }
1864
- const collection = args[0]
1865
- return isPromise(collection)
1866
- ? collection.then(curry2(_flatMap, __, flatMapper))
1867
- : _flatMap(args[0], flatMapper)
1854
+ return isPromise(arg0)
1855
+ ? arg0.then(curry2(_flatMap, __, arg1))
1856
+ : _flatMap(arg0, arg1)
1868
1857
  }
1869
1858
 
1870
1859
  const arrayForEach = function (array, callback) {
@@ -2190,18 +2179,13 @@ const _some = function (collection, predicate) {
2190
2179
  return predicate(collection)
2191
2180
  }
2192
2181
 
2193
- const some = function (...args) {
2194
- const predicate = args.pop()
2195
- if (args.length == 0) {
2196
- return curry2(_some, __, predicate)
2197
- }
2198
-
2199
- const collection = args[0]
2200
- if (isPromise(collection)) {
2201
- return collection.then(curry2(_some, __, predicate))
2182
+ const some = function (arg0, arg1) {
2183
+ if (typeof arg0 == 'function') {
2184
+ return curry2(_some, __, arg0)
2202
2185
  }
2203
-
2204
- return _some(collection, predicate)
2186
+ return isPromise(arg0)
2187
+ ? arg0.then(curry2(_some, __, arg1))
2188
+ : _some(arg0, arg1)
2205
2189
  }
2206
2190
 
2207
2191
  const arrayEvery = function (array, predicate) {
@@ -2302,18 +2286,13 @@ const _every = function (collection, predicate) {
2302
2286
  return predicate(collection)
2303
2287
  }
2304
2288
 
2305
- const every = function (...args) {
2306
- const predicate = args.pop()
2307
- if (args.length == 0) {
2308
- return curry2(_every, __, predicate)
2309
- }
2310
-
2311
- const collection = args[0]
2312
- if (isPromise(collection)) {
2313
- return collection.then(curry2(_every, __, predicate))
2289
+ const every = function (arg0, arg1) {
2290
+ if (typeof arg0 == 'function') {
2291
+ return curry2(_every, __, arg0)
2314
2292
  }
2315
-
2316
- return _every(collection, predicate)
2293
+ return isPromise(arg0)
2294
+ ? arg0.then(curry2(_every, __, arg1))
2295
+ : _every(arg0, arg1)
2317
2296
  }
2318
2297
 
2319
2298
  const areAllValuesTruthy = function (predicates, index) {