ramda-adjunct 3.3.0 → 3.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (480) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/README.md +1 -1
  3. package/dist/RA.node.js +163 -1571
  4. package/dist/RA.node.min.js +1 -1
  5. package/dist/RA.web.js +163 -1571
  6. package/dist/RA.web.min.js +1 -1
  7. package/dist/RA.web.standalone.js +164 -1571
  8. package/dist/RA.web.standalone.min.js +1 -1
  9. package/es/Y.js +1 -0
  10. package/es/allEqual.js +3 -2
  11. package/es/allEqualTo.js +1 -1
  12. package/es/allIdentical.js +1 -1
  13. package/es/allIdenticalTo.js +1 -1
  14. package/es/allP.js +1 -1
  15. package/es/allSettledP.js +1 -1
  16. package/es/allUnique.js +1 -1
  17. package/es/anyP.js +1 -1
  18. package/es/appendFlipped.js +1 -1
  19. package/es/argsPass.js +1 -1
  20. package/es/async.js +1 -5
  21. package/es/cata.js +1 -4
  22. package/es/catchP.js +1 -1
  23. package/es/ceil.js +1 -0
  24. package/es/compact.js +1 -1
  25. package/es/concatAll.js +1 -1
  26. package/es/concatRight.js +1 -1
  27. package/es/copyKeys.js +5 -5
  28. package/es/curryRight.js +1 -1
  29. package/es/curryRightN.js +1 -2
  30. package/es/defaultWhen.js +1 -1
  31. package/es/delayP.js +1 -3
  32. package/es/dispatch.js +1 -10
  33. package/es/divideNum.js +1 -1
  34. package/es/dropArgs.js +1 -1
  35. package/es/ensureArray.js +1 -1
  36. package/es/escapeRegExp.js +1 -1
  37. package/es/fantasy-land/Identity.js +15 -20
  38. package/es/fantasy-land/traits.js +4 -5
  39. package/es/fantasy-land/util.js +8 -4
  40. package/es/filterIndexed.js +1 -1
  41. package/es/findOr.js +1 -0
  42. package/es/flattenDepth.js +1 -12
  43. package/es/flattenPath.js +1 -1
  44. package/es/flattenProp.js +1 -1
  45. package/es/floor.js +1 -0
  46. package/es/fnull.js +1 -1
  47. package/es/inRange.js +1 -1
  48. package/es/included.js +1 -1
  49. package/es/index.js +18 -29
  50. package/es/internal/ap.js +0 -1
  51. package/es/internal/isOfTypeObject.js +0 -2
  52. package/es/internal/makeFlat.js +1 -6
  53. package/es/internal/ponyfills/Array.from.js +0 -12
  54. package/es/internal/ponyfills/Math.sign.js +0 -1
  55. package/es/internal/ponyfills/Math.trunc.js +2 -5
  56. package/es/internal/ponyfills/Number.isFinite.js +2 -1
  57. package/es/internal/ponyfills/Number.isNaN.js +2 -1
  58. package/es/internal/ponyfills/Promise.allSettled.js +0 -10
  59. package/es/internal/ponyfills/Promise.any.js +3 -31
  60. package/es/internal/ponyfills/String.padEnd.js +0 -6
  61. package/es/internal/ponyfills/String.padStart.js +4 -9
  62. package/es/internal/ponyfills/String.repeat.js +3 -13
  63. package/es/internal/ponyfills/String.replaceAll.js +0 -5
  64. package/es/invoke.js +1 -1
  65. package/es/invokeArgs.js +1 -0
  66. package/es/isArray.js +1 -1
  67. package/es/isArrayLike.js +2 -11
  68. package/es/isAsyncFunction.js +1 -1
  69. package/es/isBigInt.js +1 -1
  70. package/es/isBlank.js +0 -1
  71. package/es/isBoolean.js +1 -1
  72. package/es/isDate.js +1 -1
  73. package/es/isEmptyArray.js +1 -1
  74. package/es/isEmptyString.js +1 -1
  75. package/es/isError.js +1 -1
  76. package/es/isEven.js +1 -1
  77. package/es/isFalse.js +1 -0
  78. package/es/isFalsy.js +1 -1
  79. package/es/isFinite.js +1 -2
  80. package/es/isFloat.js +1 -1
  81. package/es/isFunction.js +1 -1
  82. package/es/isGeneratorFunction.js +2 -13
  83. package/es/isIndexed.js +1 -0
  84. package/es/isInteger.js +1 -1
  85. package/es/isInteger32.js +1 -1
  86. package/es/isIterable.js +1 -2
  87. package/es/isMap.js +1 -0
  88. package/es/isNaN.js +1 -2
  89. package/es/isNaturalNumber.js +1 -0
  90. package/es/isNegative.js +1 -1
  91. package/es/isNegativeZero.js +1 -1
  92. package/es/isNilOrEmpty.js +1 -1
  93. package/es/isNonEmptyArray.js +1 -1
  94. package/es/isNonEmptyString.js +1 -1
  95. package/es/isNonNegative.js +1 -1
  96. package/es/isNonPositive.js +1 -1
  97. package/es/isNotArray.js +1 -1
  98. package/es/isNotArrayLike.js +1 -1
  99. package/es/isNotAsyncFunction.js +1 -3
  100. package/es/isNotBoolean.js +1 -1
  101. package/es/isNotDate.js +1 -1
  102. package/es/isNotEmpty.js +1 -1
  103. package/es/isNotFinite.js +1 -1
  104. package/es/isNotFloat.js +1 -1
  105. package/es/isNotFunction.js +1 -3
  106. package/es/isNotGeneratorFunction.js +1 -3
  107. package/es/isNotInteger.js +1 -1
  108. package/es/isNotMap.js +1 -0
  109. package/es/isNotNaN.js +1 -1
  110. package/es/isNotNil.js +1 -1
  111. package/es/isNotNilOrEmpty.js +1 -1
  112. package/es/isNotNull.js +1 -1
  113. package/es/isNotNumber.js +1 -1
  114. package/es/isNotObj.js +1 -3
  115. package/es/isNotObjLike.js +1 -3
  116. package/es/isNotPair.js +1 -1
  117. package/es/isNotPlainObj.js +1 -3
  118. package/es/isNotPrimitive.js +1 -0
  119. package/es/isNotRegExp.js +1 -1
  120. package/es/isNotSet.js +1 -0
  121. package/es/isNotString.js +1 -1
  122. package/es/isNotUndefined.js +1 -1
  123. package/es/isNotValidDate.js +1 -1
  124. package/es/isNotValidNumber.js +1 -1
  125. package/es/isNull.js +1 -1
  126. package/es/isNumber.js +1 -1
  127. package/es/isObj.js +1 -3
  128. package/es/isObjLike.js +1 -3
  129. package/es/isOdd.js +1 -1
  130. package/es/isPair.js +1 -1
  131. package/es/isPlainObj.js +1 -6
  132. package/es/isPositive.js +1 -1
  133. package/es/isPositiveZero.js +1 -1
  134. package/es/isPrimitive.js +1 -0
  135. package/es/isPromise.js +1 -1
  136. package/es/isPrototypeOf.js +1 -1
  137. package/es/isRegExp.js +1 -1
  138. package/es/isSafeInteger.js +1 -0
  139. package/es/isSentinelValue.js +1 -1
  140. package/es/isSet.js +1 -0
  141. package/es/isSparseArray.js +1 -1
  142. package/es/isString.js +1 -1
  143. package/es/isSymbol.js +1 -2
  144. package/es/isThenable.js +1 -1
  145. package/es/isTrue.js +1 -0
  146. package/es/isTruthy.js +1 -1
  147. package/es/isUinteger32.js +1 -1
  148. package/es/isUndefined.js +1 -1
  149. package/es/isValidDate.js +1 -3
  150. package/es/isValidNumber.js +1 -1
  151. package/es/lastP.js +1 -9
  152. package/es/lengthEq.js +1 -1
  153. package/es/lengthGt.js +1 -1
  154. package/es/lengthGte.js +1 -1
  155. package/es/lengthLt.js +1 -1
  156. package/es/lengthLte.js +1 -1
  157. package/es/lengthNotEq.js +1 -1
  158. package/es/lensEq.js +1 -1
  159. package/es/lensIso.js +9 -8
  160. package/es/lensNotEq.js +1 -1
  161. package/es/lensNotSatisfy.js +1 -1
  162. package/es/lensSatisfies.js +1 -1
  163. package/es/lensTraverse.js +1 -1
  164. package/es/liftF.js +1 -1
  165. package/es/liftFN.js +1 -2
  166. package/es/list.js +1 -1
  167. package/es/mapIndexed.js +1 -1
  168. package/es/mergePath.js +1 -1
  169. package/es/mergePaths.js +1 -1
  170. package/es/mergeProp.js +1 -1
  171. package/es/mergeProps.js +1 -1
  172. package/es/move.js +1 -1
  173. package/es/nand.js +1 -1
  174. package/es/neither.js +1 -3
  175. package/es/noneP.js +1 -1
  176. package/es/nonePass.js +1 -1
  177. package/es/noop.js +1 -1
  178. package/es/nor.js +1 -1
  179. package/es/notAllPass.js +1 -1
  180. package/es/notAllUnique.js +1 -1
  181. package/es/notBoth.js +1 -3
  182. package/es/notEqual.js +1 -1
  183. package/es/omitBy.js +1 -3
  184. package/es/omitIndexes.js +3 -2
  185. package/es/overlaps.js +1 -1
  186. package/es/padCharsEnd.js +1 -1
  187. package/es/padCharsStart.js +1 -1
  188. package/es/padEnd.js +1 -1
  189. package/es/padStart.js +1 -1
  190. package/es/pathNotEq.js +1 -3
  191. package/es/pathOrLazy.js +1 -1
  192. package/es/paths.js +1 -1
  193. package/es/pickIndexes.js +3 -2
  194. package/es/propNotEq.js +1 -1
  195. package/es/rangeStep.js +1 -1
  196. package/es/reduceIndexed.js +1 -1
  197. package/es/reduceP.js +4 -16
  198. package/es/reduceRightP.js +6 -19
  199. package/es/rejectP.js +1 -1
  200. package/es/renameKeyWith.js +1 -1
  201. package/es/renameKeys.js +1 -4
  202. package/es/renameKeysWith.js +1 -1
  203. package/es/repeatStr.js +1 -1
  204. package/es/replaceAll.js +1 -1
  205. package/es/resolveP.js +1 -3
  206. package/es/round.js +1 -0
  207. package/es/seq.js +1 -2
  208. package/es/sign.js +1 -0
  209. package/es/skipTake.js +1 -0
  210. package/es/sliceFrom.js +1 -1
  211. package/es/sliceTo.js +1 -1
  212. package/es/sortByPaths.js +1 -0
  213. package/es/sortByProp.js +42 -0
  214. package/es/sortByProps.js +3 -11
  215. package/es/spreadPath.js +1 -1
  216. package/es/spreadProp.js +1 -1
  217. package/es/stubArray.js +1 -1
  218. package/es/stubNull.js +1 -1
  219. package/es/stubObj.js +1 -1
  220. package/es/stubString.js +1 -1
  221. package/es/stubUndefined.js +1 -1
  222. package/es/subtractNum.js +1 -1
  223. package/es/thenCatchP.js +1 -1
  224. package/es/toArray.js +1 -0
  225. package/es/toInteger32.js +0 -1
  226. package/es/toNumber.js +1 -1
  227. package/es/toUinteger32.js +2 -1
  228. package/es/trimCharsEnd.js +1 -0
  229. package/es/trimCharsStart.js +1 -0
  230. package/es/trimEnd.js +1 -0
  231. package/es/trimStart.js +1 -0
  232. package/es/trunc.js +1 -0
  233. package/es/unzipObjWith.js +1 -1
  234. package/es/viewOr.js +1 -0
  235. package/es/weave.js +1 -1
  236. package/es/weaveLazy.js +1 -1
  237. package/es/zipObjWith.js +1 -1
  238. package/lib/Y.js +1 -2
  239. package/lib/allEqual.js +0 -4
  240. package/lib/allEqualTo.js +0 -2
  241. package/lib/allIdentical.js +0 -4
  242. package/lib/allIdenticalTo.js +0 -2
  243. package/lib/allP.js +0 -2
  244. package/lib/allSettledP.js +1 -6
  245. package/lib/allUnique.js +0 -4
  246. package/lib/anyP.js +0 -10
  247. package/lib/appendFlipped.js +0 -2
  248. package/lib/argsPass.js +0 -5
  249. package/lib/async.js +0 -9
  250. package/lib/cata.js +0 -7
  251. package/lib/catchP.js +0 -2
  252. package/lib/ceil.js +1 -2
  253. package/lib/compact.js +0 -4
  254. package/lib/concatAll.js +1 -5
  255. package/lib/concatRight.js +0 -2
  256. package/lib/copyKeys.js +4 -8
  257. package/lib/curryRight.js +0 -4
  258. package/lib/curryRightN.js +0 -3
  259. package/lib/defaultWhen.js +0 -2
  260. package/lib/delayP.js +1 -8
  261. package/lib/dispatch.js +0 -15
  262. package/lib/divideNum.js +0 -2
  263. package/lib/dropArgs.js +0 -2
  264. package/lib/ensureArray.js +0 -4
  265. package/lib/escapeRegExp.js +0 -4
  266. package/lib/fantasy-land/Identity.js +14 -27
  267. package/lib/fantasy-land/traits.js +4 -28
  268. package/lib/fantasy-land/util.js +6 -5
  269. package/lib/filterIndexed.js +0 -2
  270. package/lib/findOr.js +1 -2
  271. package/lib/flattenDepth.js +1 -14
  272. package/lib/flattenPath.js +0 -2
  273. package/lib/flattenProp.js +0 -4
  274. package/lib/floor.js +1 -2
  275. package/lib/fnull.js +1 -6
  276. package/lib/inRange.js +1 -4
  277. package/lib/included.js +0 -2
  278. package/lib/index.js +4 -425
  279. package/lib/internal/ap.js +0 -9
  280. package/lib/internal/compareLength.js +0 -2
  281. package/lib/internal/isCoercible.js +0 -6
  282. package/lib/internal/isOfTypeObject.js +0 -3
  283. package/lib/internal/makeFlat.js +0 -8
  284. package/lib/internal/ponyfills/Array.from.js +0 -18
  285. package/lib/internal/ponyfills/Math.sign.js +0 -2
  286. package/lib/internal/ponyfills/Math.trunc.js +2 -7
  287. package/lib/internal/ponyfills/Number.isFinite.js +0 -4
  288. package/lib/internal/ponyfills/Number.isInteger.js +0 -4
  289. package/lib/internal/ponyfills/Number.isNaN.js +0 -4
  290. package/lib/internal/ponyfills/Number.isSafeInteger.js +0 -5
  291. package/lib/internal/ponyfills/Promise.allSettled.js +0 -14
  292. package/lib/internal/ponyfills/Promise.any.js +3 -36
  293. package/lib/internal/ponyfills/String.padEnd.js +0 -10
  294. package/lib/internal/ponyfills/String.padStart.js +4 -13
  295. package/lib/internal/ponyfills/String.repeat.js +3 -16
  296. package/lib/internal/ponyfills/String.replaceAll.js +0 -9
  297. package/lib/internal/ponyfills/String.trimEnd.js +0 -2
  298. package/lib/internal/ponyfills/String.trimStart.js +0 -2
  299. package/lib/invoke.js +0 -4
  300. package/lib/invokeArgs.js +1 -5
  301. package/lib/isArray.js +0 -4
  302. package/lib/isArrayLike.js +0 -16
  303. package/lib/isAsyncFunction.js +0 -2
  304. package/lib/isBigInt.js +0 -2
  305. package/lib/isBlank.js +0 -4
  306. package/lib/isBoolean.js +0 -2
  307. package/lib/isDate.js +0 -2
  308. package/lib/isEmptyArray.js +0 -4
  309. package/lib/isEmptyString.js +0 -2
  310. package/lib/isError.js +0 -2
  311. package/lib/isEven.js +0 -5
  312. package/lib/isFalse.js +1 -2
  313. package/lib/isFalsy.js +0 -4
  314. package/lib/isFinite.js +1 -8
  315. package/lib/isFloat.js +0 -5
  316. package/lib/isFunction.js +0 -5
  317. package/lib/isGeneratorFunction.js +1 -15
  318. package/lib/isIndexed.js +1 -5
  319. package/lib/isInteger.js +1 -6
  320. package/lib/isInteger32.js +0 -4
  321. package/lib/isIterable.js +0 -5
  322. package/lib/isMap.js +1 -2
  323. package/lib/isNaN.js +1 -8
  324. package/lib/isNaturalNumber.js +1 -5
  325. package/lib/isNegative.js +0 -4
  326. package/lib/isNegativeZero.js +0 -2
  327. package/lib/isNilOrEmpty.js +0 -2
  328. package/lib/isNonEmptyArray.js +0 -5
  329. package/lib/isNonEmptyString.js +0 -6
  330. package/lib/isNonNegative.js +0 -4
  331. package/lib/isNonPositive.js +0 -4
  332. package/lib/isNotArray.js +0 -4
  333. package/lib/isNotArrayLike.js +0 -4
  334. package/lib/isNotAsyncFunction.js +0 -6
  335. package/lib/isNotBoolean.js +0 -4
  336. package/lib/isNotDate.js +0 -4
  337. package/lib/isNotEmpty.js +0 -2
  338. package/lib/isNotFinite.js +0 -4
  339. package/lib/isNotFloat.js +0 -4
  340. package/lib/isNotFunction.js +0 -6
  341. package/lib/isNotGeneratorFunction.js +0 -6
  342. package/lib/isNotInteger.js +0 -4
  343. package/lib/isNotMap.js +1 -4
  344. package/lib/isNotNaN.js +0 -4
  345. package/lib/isNotNil.js +0 -2
  346. package/lib/isNotNilOrEmpty.js +0 -4
  347. package/lib/isNotNull.js +0 -4
  348. package/lib/isNotNumber.js +0 -4
  349. package/lib/isNotObj.js +0 -6
  350. package/lib/isNotObjLike.js +0 -6
  351. package/lib/isNotPair.js +0 -4
  352. package/lib/isNotPlainObj.js +0 -6
  353. package/lib/isNotPrimitive.js +1 -4
  354. package/lib/isNotRegExp.js +0 -4
  355. package/lib/isNotSet.js +1 -4
  356. package/lib/isNotString.js +0 -4
  357. package/lib/isNotUndefined.js +0 -4
  358. package/lib/isNotValidDate.js +0 -4
  359. package/lib/isNotValidNumber.js +0 -4
  360. package/lib/isNull.js +0 -2
  361. package/lib/isNumber.js +0 -2
  362. package/lib/isObj.js +0 -8
  363. package/lib/isObjLike.js +0 -7
  364. package/lib/isOdd.js +0 -4
  365. package/lib/isPair.js +0 -4
  366. package/lib/isPlainObj.js +1 -12
  367. package/lib/isPositive.js +0 -4
  368. package/lib/isPositiveZero.js +0 -2
  369. package/lib/isPrimitive.js +1 -11
  370. package/lib/isPromise.js +0 -4
  371. package/lib/isPrototypeOf.js +0 -4
  372. package/lib/isRegExp.js +0 -2
  373. package/lib/isSafeInteger.js +1 -6
  374. package/lib/isSentinelValue.js +0 -4
  375. package/lib/isSet.js +1 -2
  376. package/lib/isSparseArray.js +0 -4
  377. package/lib/isString.js +0 -2
  378. package/lib/isSymbol.js +0 -3
  379. package/lib/isThenable.js +0 -4
  380. package/lib/isTrue.js +1 -2
  381. package/lib/isTruthy.js +0 -2
  382. package/lib/isUinteger32.js +0 -4
  383. package/lib/isUndefined.js +0 -4
  384. package/lib/isValidDate.js +0 -7
  385. package/lib/isValidNumber.js +0 -5
  386. package/lib/lastP.js +0 -16
  387. package/lib/lengthEq.js +0 -4
  388. package/lib/lengthGt.js +0 -4
  389. package/lib/lengthGte.js +0 -4
  390. package/lib/lengthLt.js +0 -4
  391. package/lib/lengthLte.js +0 -4
  392. package/lib/lengthNotEq.js +0 -4
  393. package/lib/lensEq.js +0 -2
  394. package/lib/lensIso.js +6 -8
  395. package/lib/lensNotEq.js +0 -4
  396. package/lib/lensNotSatisfy.js +0 -4
  397. package/lib/lensSatisfies.js +0 -4
  398. package/lib/lensTraverse.js +0 -4
  399. package/lib/liftF.js +0 -4
  400. package/lib/liftFN.js +0 -5
  401. package/lib/list.js +0 -2
  402. package/lib/mapIndexed.js +0 -2
  403. package/lib/mergePath.js +0 -2
  404. package/lib/mergePaths.js +0 -4
  405. package/lib/mergeProp.js +0 -4
  406. package/lib/mergeProps.js +0 -2
  407. package/lib/move.js +0 -2
  408. package/lib/nand.js +0 -3
  409. package/lib/neither.js +0 -4
  410. package/lib/noneP.js +0 -6
  411. package/lib/nonePass.js +0 -2
  412. package/lib/noop.js +0 -4
  413. package/lib/nor.js +0 -3
  414. package/lib/notAllPass.js +0 -2
  415. package/lib/notAllUnique.js +0 -4
  416. package/lib/notBoth.js +0 -4
  417. package/lib/notEqual.js +0 -2
  418. package/lib/omitBy.js +0 -4
  419. package/lib/omitIndexes.js +1 -3
  420. package/lib/overlaps.js +1 -5
  421. package/lib/padCharsEnd.js +1 -6
  422. package/lib/padCharsStart.js +1 -6
  423. package/lib/padEnd.js +0 -3
  424. package/lib/padStart.js +0 -3
  425. package/lib/pathNotEq.js +0 -4
  426. package/lib/pathOrLazy.js +0 -2
  427. package/lib/paths.js +0 -2
  428. package/lib/pickIndexes.js +1 -3
  429. package/lib/propNotEq.js +0 -2
  430. package/lib/rangeStep.js +0 -4
  431. package/lib/reduceIndexed.js +0 -2
  432. package/lib/reduceP.js +3 -21
  433. package/lib/reduceRightP.js +4 -24
  434. package/lib/rejectP.js +0 -2
  435. package/lib/renameKeyWith.js +0 -4
  436. package/lib/renameKeys.js +1 -7
  437. package/lib/renameKeysWith.js +0 -2
  438. package/lib/repeatStr.js +1 -6
  439. package/lib/replaceAll.js +1 -6
  440. package/lib/resolveP.js +0 -4
  441. package/lib/round.js +1 -2
  442. package/lib/seq.js +1 -4
  443. package/lib/sign.js +1 -6
  444. package/lib/skipTake.js +1 -2
  445. package/lib/sliceFrom.js +0 -2
  446. package/lib/sliceTo.js +0 -2
  447. package/lib/sortByPaths.js +1 -2
  448. package/lib/sortByProp.js +47 -0
  449. package/lib/sortByProps.js +3 -13
  450. package/lib/spreadPath.js +0 -2
  451. package/lib/spreadProp.js +0 -4
  452. package/lib/stubArray.js +1 -2
  453. package/lib/stubNull.js +0 -2
  454. package/lib/stubObj.js +1 -2
  455. package/lib/stubString.js +0 -2
  456. package/lib/stubUndefined.js +0 -3
  457. package/lib/subtractNum.js +0 -2
  458. package/lib/thenCatchP.js +0 -2
  459. package/lib/toArray.js +1 -6
  460. package/lib/toInteger32.js +0 -2
  461. package/lib/toNumber.js +0 -4
  462. package/lib/toUinteger32.js +1 -2
  463. package/lib/trimCharsEnd.js +1 -4
  464. package/lib/trimCharsStart.js +1 -4
  465. package/lib/trimEnd.js +1 -6
  466. package/lib/trimStart.js +1 -6
  467. package/lib/trunc.js +1 -6
  468. package/lib/unzipObjWith.js +0 -4
  469. package/lib/viewOr.js +1 -2
  470. package/lib/weave.js +0 -2
  471. package/lib/weaveLazy.js +0 -2
  472. package/lib/zipObjWith.js +0 -2
  473. package/package.json +30 -28
  474. package/src/index.js +1 -0
  475. package/src/isGeneratorFunction.js +2 -19
  476. package/src/sortByProp.js +45 -0
  477. package/src/sortByProps.js +1 -1
  478. package/types/.eslintrc.js +23 -0
  479. package/types/dtslint.eslint.js +13 -0
  480. package/types/index.d.ts +24 -5
package/es/seq.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { curry, map, tap } from 'ramda';
2
- /* eslint-disable max-len */
3
2
 
3
+ /* eslint-disable max-len */
4
4
  /**
5
5
  * Runs the given list of functions in order with the supplied object, then returns the object.
6
6
  * Also known as the normal order sequencing combinator.
@@ -31,7 +31,6 @@ import { curry, map, tap } from 'ramda';
31
31
  * R.toUpper
32
32
  * )('test'); //=> 'PREFIX TEST'
33
33
  */
34
-
35
34
  /* eslint-enable max-len */
36
35
 
37
36
  var seq = curry(function (fns, x) {
package/es/sign.js CHANGED
@@ -2,6 +2,7 @@ import { bind, curryN } from 'ramda';
2
2
  import isFunction from './isFunction';
3
3
  import ponyfill from './internal/ponyfills/Math.sign';
4
4
  export var signPonyfill = curryN(1, ponyfill);
5
+
5
6
  /**
6
7
  * Returns the sign of a number, indicating whether the number is positive, negative or zero.
7
8
  *
package/es/skipTake.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { curry, addIndex, filter, pipe, modulo, identical, nthArg, __ } from 'ramda';
2
+
2
3
  /**
3
4
  * When given a number n and an array, returns an array containing every nth element.
4
5
  *
package/es/sliceFrom.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { __, slice } from 'ramda';
2
+
2
3
  /**
3
4
  * Returns the elements of the given list or string (or object with a slice method)
4
5
  * from fromIndex (inclusive).
@@ -17,6 +18,5 @@ import { __, slice } from 'ramda';
17
18
  *
18
19
  * RA.sliceFrom(1, [1, 2, 3]); //=> [2, 3]
19
20
  */
20
-
21
21
  var sliceFrom = slice(__, Infinity);
22
22
  export default sliceFrom;
package/es/sliceTo.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { slice } from 'ramda';
2
+
2
3
  /**
3
4
  * Returns the elements of the given list or string (or object with a slice method)
4
5
  * to toIndex (exclusive).
@@ -17,6 +18,5 @@ import { slice } from 'ramda';
17
18
  *
18
19
  * RA.sliceTo(2, [1, 2, 3]); //=> [1, 2]
19
20
  */
20
-
21
21
  var sliceTo = slice(0);
22
22
  export default sliceTo;
package/es/sortByPaths.js CHANGED
@@ -1,6 +1,7 @@
1
1
  import { ascend, identity, map, path, pipe, sortWith, useWith } from 'ramda';
2
2
  var pathToAscendSort = pipe(path, ascend);
3
3
  var mapPathsToAscendSort = map(pathToAscendSort);
4
+
4
5
  /**
5
6
  * Sort a list of objects by a list of paths (if first path value is equivalent, sort by second, etc).
6
7
  *
@@ -0,0 +1,42 @@
1
+ import { __, append, identity, useWith } from 'ramda';
2
+ import sortByProps from './sortByProps';
3
+
4
+ /**
5
+ * Sort a list of objects by a property.
6
+ *
7
+ * @func sortByProp
8
+ * @memberOf RA
9
+ * @since {@link https://char0n.github.io/ramda-adjunct/3.4.0|v3.4.0}
10
+ * @category List
11
+ * @sig k -> [{k: v}] -> [{k: v}]
12
+ * @param {Array.<string>} prop The property in the list param to sort by
13
+ * @param {Array.<object>} list A list of objects to be sorted
14
+ * @return {Array.<object>} A new list sorted by the property in the prop param
15
+ * @example
16
+ *
17
+ * // sorting list of tuples
18
+ * const sortByFirstItem = sortByProp(0);
19
+ * const listOfTuples = [[-1, 1], [-2, 2], [-3, 3]];
20
+ * sortByFirstItem(listOfTuples); // => [[-3, 3], [-2, 2], [-1, 1]]
21
+ *
22
+ * // sorting list of objects
23
+ * const sortByName = sortByProp('name');
24
+ * const alice = {
25
+ * name: 'ALICE',
26
+ * age: 101,
27
+ * };
28
+ * const bob = {
29
+ * name: 'Bob',
30
+ * age: -10,
31
+ * };
32
+ * const clara = {
33
+ * name: 'clara',
34
+ * age: 314.159,
35
+ * };
36
+ * const people = [clara, bob, alice];
37
+ * sortByName(people); // => [alice, bob, clara]
38
+ */
39
+
40
+ var addValueInAnArray = append(__, []);
41
+ var sortByProp = useWith(sortByProps, [addValueInAnArray, identity]);
42
+ export default sortByProp;
package/es/sortByProps.js CHANGED
@@ -1,16 +1,11 @@
1
1
  function _toArray(arr) { return _arrayWithHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableRest(); }
2
-
3
2
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
4
-
5
3
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
6
-
7
4
  function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
8
-
9
5
  function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
10
-
11
6
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import { comparator, curry, either, lt, map, prop, reduce, sort } from 'ramda';
12
8
 
13
- import { reduce, either, curry, prop, sort, comparator, map, lt } from 'ramda';
14
9
  /**
15
10
  * Sort a list of objects by a list of props (if first prop value is equivalent, sort by second, etc).
16
11
  *
@@ -35,18 +30,15 @@ import { reduce, either, curry, prop, sort, comparator, map, lt } from 'ramda';
35
30
  var sortByProps = curry(function (props, list) {
36
31
  var firstTruthy = function firstTruthy(_ref) {
37
32
  var _ref2 = _toArray(_ref),
38
- head = _ref2[0],
39
- tail = _ref2.slice(1);
40
-
33
+ head = _ref2[0],
34
+ tail = _ref2.slice(1);
41
35
  return reduce(either, head, tail);
42
36
  };
43
-
44
37
  var makeComparator = function makeComparator(propName) {
45
38
  return comparator(function (a, b) {
46
39
  return lt(prop(propName, a), prop(propName, b));
47
40
  });
48
41
  };
49
-
50
42
  return sort(firstTruthy(map(makeComparator, props)), list);
51
43
  });
52
44
  export default sortByProps;
package/es/spreadPath.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { curryN, converge, mergeRight, dissocPath, pathOr } from 'ramda';
2
+
2
3
  /**
3
4
  * Spreads object under property path onto provided object.
4
5
  * It's like {@link RA.flattenPath|flattenPath}, but removes object under the property path.
@@ -20,6 +21,5 @@ import { curryN, converge, mergeRight, dissocPath, pathOr } from 'ramda';
20
21
  * { a: 1, b1: { b2: { c: 3, d: 4 } } }
21
22
  * ); // => { a: 1, c: 3, d: 4, b1: {} };
22
23
  */
23
-
24
24
  var spreadPath = curryN(2, converge(mergeRight, [dissocPath, pathOr({})]));
25
25
  export default spreadPath;
package/es/spreadProp.js CHANGED
@@ -1,5 +1,6 @@
1
1
  import { of, curry } from 'ramda';
2
2
  import spreadPath from './spreadPath';
3
+
3
4
  /**
4
5
  * Spreads object under property onto provided object.
5
6
  * It's like {@link RA.flattenProp|flattenProp}, but removes object under the property.
@@ -18,7 +19,6 @@ import spreadPath from './spreadPath';
18
19
  *
19
20
  * RA.spreadProp('b', { a: 1, b: { c: 3, d: 4 } }); // => { a: 1, c: 3, d: 4 };
20
21
  */
21
-
22
22
  var spreadProp = curry(function (prop, obj) {
23
23
  return spreadPath(of(prop), obj);
24
24
  });
package/es/stubArray.js CHANGED
@@ -12,8 +12,8 @@
12
12
  * RA.stubArray(); //=> []
13
13
  * RA.stubArray(1, 2, 3); //=> []
14
14
  */
15
+
15
16
  var stubArray = function stubArray() {
16
17
  return [];
17
18
  };
18
-
19
19
  export default stubArray;
package/es/stubNull.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { always } from 'ramda';
2
+
2
3
  /**
3
4
  * A function that returns `null`.
4
5
  *
@@ -13,6 +14,5 @@ import { always } from 'ramda';
13
14
  * RA.stubNull(); //=> null
14
15
  * RA.stubNull(1, 2, 3); //=> null
15
16
  */
16
-
17
17
  var stubNull = always(null);
18
18
  export default stubNull;
package/es/stubObj.js CHANGED
@@ -13,8 +13,8 @@
13
13
  * RA.stubObj(); //=> {}
14
14
  * RA.stubObj(1, 2, 3); //=> {}
15
15
  */
16
+
16
17
  var stubObj = function stubObj() {
17
18
  return {};
18
19
  };
19
-
20
20
  export default stubObj;
package/es/stubString.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { always } from 'ramda';
2
+
2
3
  /**
3
4
  * A function that returns empty string.
4
5
  *
@@ -13,6 +14,5 @@ import { always } from 'ramda';
13
14
  * RA.stubString(); //=> ''
14
15
  * RA.stubString(1, 2, 3); //=> ''
15
16
  */
16
-
17
17
  var stubString = always('');
18
18
  export default stubString;
@@ -1,4 +1,5 @@
1
1
  import { always } from 'ramda';
2
+
2
3
  /**
3
4
  * A function that returns `undefined`.
4
5
  *
@@ -13,7 +14,6 @@ import { always } from 'ramda';
13
14
  * RA.stubUndefined(); //=> undefined
14
15
  * RA.stubUndefined(1, 2, 3); //=> undefined
15
16
  */
16
-
17
17
  var stubUndefined = always(void 0); // eslint-disable-line no-void
18
18
 
19
19
  export default stubUndefined;
package/es/subtractNum.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { flip, subtract } from 'ramda';
2
+
2
3
  /**
3
4
  * Subtracts its first argument from its second argument.
4
5
  *
@@ -14,6 +15,5 @@ import { flip, subtract } from 'ramda';
14
15
  *
15
16
  * RA.subtractNum(3, 5); //=> 2
16
17
  */
17
-
18
18
  var subtractNum = flip(subtract);
19
19
  export default subtractNum;
package/es/thenCatchP.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { invoker } from 'ramda';
2
+
2
3
  /**
3
4
  * Composable shortcut for `Promise.then` that allows for success and failure callbacks.
4
5
  * The thenCatchP function returns a Promise. It takes three arguments: a callback function for the success of the Promise,
@@ -21,6 +22,5 @@ import { invoker } from 'ramda';
21
22
  *
22
23
  * RA.thenCatchP(add1, console.error, promise); // => Promise(2)
23
24
  */
24
-
25
25
  export var thenCatchP = invoker(2, 'then');
26
26
  export default thenCatchP;
package/es/toArray.js CHANGED
@@ -4,6 +4,7 @@ import isFunction from './isFunction';
4
4
  import ponyfill from './internal/ponyfills/Array.from';
5
5
  export var fromPonyfill = curryN(1, ponyfill);
6
6
  var fromArray = isFunction(Array.from) ? curryN(1, Array.from) : fromPonyfill;
7
+
7
8
  /**
8
9
  * Converts value to an array.
9
10
  *
package/es/toInteger32.js CHANGED
@@ -17,7 +17,6 @@ import { curryN } from 'ramda';
17
17
  * RA.toInteger32(2 ** 30); // => 1073741824
18
18
  */
19
19
  // eslint-disable-next-line no-bitwise
20
-
21
20
  var toInteger32 = curryN(1, function (val) {
22
21
  return val >> 0;
23
22
  });
package/es/toNumber.js CHANGED
@@ -1,5 +1,6 @@
1
1
  import { ifElse, always } from 'ramda';
2
2
  import isCoercible from './internal/isCoercible';
3
+
3
4
  /**
4
5
  * Converts value to a number.
5
6
  *
@@ -17,6 +18,5 @@ import isCoercible from './internal/isCoercible';
17
18
  * RA.toNumber('3.2'); //=> 3.2
18
19
  * RA.toNumber(Symbol('3.2')); //=> NaN
19
20
  */
20
-
21
21
  var toNumber = ifElse(isCoercible, Number, always(NaN));
22
22
  export default toNumber;
@@ -1,4 +1,5 @@
1
1
  import { curryN } from 'ramda';
2
+
2
3
  /**
3
4
  * Converts double-precision 64-bit binary format IEEE 754 to unsigned 32 bit integer number.
4
5
  *
@@ -18,8 +19,8 @@ import { curryN } from 'ramda';
18
19
  * RA.toInteger32(2 ** 31); // => 2147483648
19
20
  * RA.toInteger32(2 ** 30); // => 1073741824
20
21
  */
21
- // eslint-disable-next-line no-bitwise
22
22
 
23
+ // eslint-disable-next-line no-bitwise
23
24
  var toUinteger32 = curryN(1, function (val) {
24
25
  return val >>> 0;
25
26
  });
@@ -1,5 +1,6 @@
1
1
  import { curry, dropLastWhile, join, pipe, split } from 'ramda';
2
2
  import included from './included';
3
+
3
4
  /**
4
5
  * Removes specified characters from the end of a string.
5
6
  *
@@ -1,5 +1,6 @@
1
1
  import { curry, dropWhile, join, pipe, split } from 'ramda';
2
2
  import included from './included';
3
+
3
4
  /**
4
5
  * Removes specified characters from the beginning of a string.
5
6
  *
package/es/trimEnd.js CHANGED
@@ -3,6 +3,7 @@ import ponyfill from './internal/ponyfills/String.trimEnd';
3
3
  import isFunction from './isFunction';
4
4
  export var trimEndPonyfill = ponyfill;
5
5
  export var trimEndInvoker = invoker(0, 'trimEnd');
6
+
6
7
  /**
7
8
  * Removes whitespace from the end of a string.
8
9
  *
package/es/trimStart.js CHANGED
@@ -3,6 +3,7 @@ import ponyfill from './internal/ponyfills/String.trimStart';
3
3
  import isFunction from './isFunction';
4
4
  export var trimStartPonyfill = ponyfill;
5
5
  export var trimStartInvoker = invoker(0, 'trimStart');
6
+
6
7
  /**
7
8
  * Removes whitespace from the beginning of a string.
8
9
  *
package/es/trunc.js CHANGED
@@ -2,6 +2,7 @@ import { bind, curryN } from 'ramda';
2
2
  import ponyfill from './internal/ponyfills/Math.trunc';
3
3
  import isFunction from './isFunction';
4
4
  export var truncPonyfill = curryN(1, ponyfill);
5
+
5
6
  /**
6
7
  * Returns the integer part of a number by removing any fractional digits.
7
8
  *
@@ -1,5 +1,6 @@
1
1
  import { apply, curryN, flip, map, pipe, toPairs, transpose, when } from 'ramda';
2
2
  import lengthEq from './lengthEq';
3
+
3
4
  /**
4
5
  * Creates a new list out of the supplied object by applying the function to each key/value pairing.
5
6
  *
@@ -17,7 +18,6 @@ import lengthEq from './lengthEq';
17
18
  * RA.unzipObjWith((v, k) => [`new${k.toUpperCase()}`, 2 * v], { a: 1, b: 2, c: 3 });
18
19
  * //=> [['newA', 'newB', 'newC'], [2, 4, 6]]
19
20
  */
20
-
21
21
  var unzipObjWith = curryN(2, function (fn, obj) {
22
22
  return pipe(toPairs, map(pipe(flip, apply)(fn)), transpose, when(lengthEq(0), function () {
23
23
  return [[], []];
package/es/viewOr.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { view, defaultTo, curryN } from 'ramda';
2
+
2
3
  /**
3
4
  * Returns a "view" of the given data structure, determined by the given lens.
4
5
  * The lens's focus determines which portion of the data structure is visible.
package/es/weave.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { curryN } from 'ramda';
2
+
2
3
  /**
3
4
  * Weaves a configuration into function returning the runnable monad like `Reader` or `Free`.
4
5
  * This allows us to pre-bind the configuration in advance and use the weaved function
@@ -27,7 +28,6 @@ import { curryN } from 'ramda';
27
28
  * const wlog = RA.weave(log, console);
28
29
  * wlog('test'); //=> prints 'test'
29
30
  */
30
-
31
31
  var weave = curryN(2, function (fn, config) {
32
32
  return curryN(fn.length, function () {
33
33
  return fn.apply(void 0, arguments).run(config);
package/es/weaveLazy.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { curryN } from 'ramda';
2
+
2
3
  /**
3
4
  * Weaves a configuration into function returning the runnable monad like `Reader` or `Free`.
4
5
  * This allows us to pre-bind the configuration in advance and use the weaved function
@@ -29,7 +30,6 @@ import { curryN } from 'ramda';
29
30
  * const wlog = RA.weaveLazy(log, consoleAccessor);
30
31
  * wlog('test'); //=> prints 'test'
31
32
  */
32
-
33
33
  var weaveLazy = curryN(2, function (fn, configAccessor) {
34
34
  return curryN(fn.length, function () {
35
35
  return fn.apply(void 0, arguments).run(configAccessor());
package/es/zipObjWith.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { apply, curryN, fromPairs, map, pipe, zip } from 'ramda';
2
+
2
3
  /**
3
4
  * Creates a new object out of a list of keys and a list of values by applying the function
4
5
  * to each equally-positioned pair in the lists.
@@ -19,7 +20,6 @@ import { apply, curryN, fromPairs, map, pipe, zip } from 'ramda';
19
20
  * RA.zipObjWith((value, key) => [key, `${key}${value + 1}`]), ['a', 'b', 'c'], [1, 2, 3]);
20
21
  * // => { a: 'a2', b: 'b3', c: 'c4' }
21
22
  */
22
-
23
23
  var zipObjWith = curryN(3, function (fn, keys, values) {
24
24
  return pipe(zip, map(apply(fn)), fromPairs)(values, keys);
25
25
  });
package/lib/Y.js CHANGED
@@ -2,9 +2,7 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  /**
9
7
  * Y-combinator
10
8
  *
@@ -31,6 +29,7 @@ var _ramda = require("ramda");
31
29
  *
32
30
  * factorial(5); //=> 120
33
31
  */
32
+
34
33
  var Y = (0, _ramda.curryN)(1, function (le) {
35
34
  return function (f) {
36
35
  return f(f);
package/lib/allEqual.js CHANGED
@@ -2,13 +2,9 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  var _lengthLte = _interopRequireDefault(require("./lengthLte"));
9
-
10
7
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
11
-
12
8
  // Original idea for this function was conceived by https://github.com/jackmellis
13
9
  // in https://github.com/char0n/ramda-adjunct/pull/513.
14
10
 
package/lib/allEqualTo.js CHANGED
@@ -2,9 +2,7 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  /**
9
7
  * Returns true if all items in the list are equivalent to user provided value using `R.equals` for equality comparisons.
10
8
  *
@@ -2,13 +2,9 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  var _lengthLte = _interopRequireDefault(require("./lengthLte"));
9
-
10
7
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
11
-
12
8
  /**
13
9
  * Returns true if all items in the list are equivalent using `R.identical` for equality comparisons.
14
10
  *
@@ -2,9 +2,7 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  /**
9
7
  * Returns true if all items in the list are equivalent to user provided value using `R.identical` for equality comparisons.
10
8
  *
package/lib/allP.js CHANGED
@@ -2,9 +2,7 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  /**
9
7
  * Composable shortcut for `Promise.all`.
10
8
  *
@@ -2,16 +2,12 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = exports.allSettledPPonyfill = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  var _isFunction = _interopRequireDefault(require("./isFunction"));
9
-
10
7
  var _Promise = _interopRequireDefault(require("./internal/ponyfills/Promise.allSettled"));
11
-
12
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
-
14
9
  var allSettledPPonyfill = (0, _ramda.curryN)(1, _Promise["default"]);
10
+
15
11
  /**
16
12
  * Returns a promise that is fulfilled with an array of promise state snapshots,
17
13
  * but only after all the original promises have settled, i.e. become either fulfilled or rejected.
@@ -34,7 +30,6 @@ var allSettledPPonyfill = (0, _ramda.curryN)(1, _Promise["default"]);
34
30
  * Promise.reject(3),
35
31
  * ]); //=> Promise([{ status: 'fulfilled', value: 1 }, { status: 'fulfilled', value: 2 }, { status: 'rejected', reason: 3 }])
36
32
  */
37
-
38
33
  exports.allSettledPPonyfill = allSettledPPonyfill;
39
34
  var allSettledP = (0, _isFunction["default"])(Promise.allSettled) ? (0, _ramda.curryN)(1, (0, _ramda.bind)(Promise.allSettled, Promise)) : allSettledPPonyfill;
40
35
  var _default = allSettledP;
package/lib/allUnique.js CHANGED
@@ -2,13 +2,9 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  var _lengthEq = _interopRequireDefault(require("./lengthEq"));
9
-
10
7
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
11
-
12
8
  /**
13
9
  * Returns true if all items in the list are unique. `R.equals` is used to determine equality.
14
10
  *
package/lib/anyP.js CHANGED
@@ -1,27 +1,17 @@
1
1
  "use strict";
2
2
 
3
3
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
4
  exports.__esModule = true;
6
5
  exports["default"] = exports.anyPPonyfill = void 0;
7
-
8
6
  var _ramda = require("ramda");
9
-
10
7
  var _isFunction = _interopRequireDefault(require("./isFunction"));
11
-
12
8
  var _Promise = _interopRequireWildcard(require("./internal/ponyfills/Promise.any"));
13
-
14
9
  exports.AggregatedError = _Promise.AggregatedError;
15
-
16
10
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
17
-
18
11
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
19
-
20
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
21
-
22
13
  var anyPPonyfill = (0, _ramda.curryN)(1, _Promise["default"]);
23
14
  exports.anyPPonyfill = anyPPonyfill;
24
-
25
15
  /**
26
16
  * Returns a promise that is fulfilled by the first given promise to be fulfilled,
27
17
  * or rejected with an array of rejection reasons if all of the given promises are rejected.
@@ -2,9 +2,7 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  /**
9
7
  * Returns a new list containing the contents of the given list, followed by the given element.
10
8
  * Like {@link http://ramdajs.com/docs/#append|R.append} but with argument order reversed.
package/lib/argsPass.js CHANGED
@@ -2,15 +2,10 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  var _list = _interopRequireDefault(require("./list"));
9
-
10
7
  var _isTruthy = _interopRequireDefault(require("./isTruthy"));
11
-
12
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
-
14
9
  /**
15
10
  * Takes a combining predicate and a list of functions and returns a function which will map the
16
11
  * arguments it receives to the list of functions and returns the result of passing the values
package/lib/async.js CHANGED
@@ -2,15 +2,10 @@
2
2
 
3
3
  exports.__esModule = true;
4
4
  exports["default"] = void 0;
5
-
6
5
  var _ramda = require("ramda");
7
-
8
6
  var _resolveP = _interopRequireDefault(require("./resolveP"));
9
-
10
7
  var _rejectP = _interopRequireDefault(require("./rejectP"));
11
-
12
8
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
-
14
9
  /**
15
10
  * Takes a generator function and returns an async function.
16
11
  * The async function returned is a curried function whose arity matches that of the generator function.
@@ -40,7 +35,6 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
40
35
  var async = (0, _ramda.curryN)(1, function (generatorFn) {
41
36
  function asyncWrapper() {
42
37
  var iterator = (0, _ramda.bind)(generatorFn, this).apply(void 0, arguments);
43
-
44
38
  var handle = function handle(result) {
45
39
  var resolved = (0, _resolveP["default"])(result.value);
46
40
  return result.done ? resolved : resolved.then(function (value) {
@@ -49,18 +43,15 @@ var async = (0, _ramda.curryN)(1, function (generatorFn) {
49
43
  return handle(iterator["throw"](error));
50
44
  });
51
45
  };
52
-
53
46
  try {
54
47
  return handle(iterator.next());
55
48
  } catch (error) {
56
49
  return (0, _rejectP["default"])(error);
57
50
  }
58
51
  }
59
-
60
52
  if (generatorFn.length > 0) {
61
53
  return (0, _ramda.curryN)(generatorFn.length, asyncWrapper);
62
54
  }
63
-
64
55
  return asyncWrapper;
65
56
  });
66
57
  var _default = async;