@typed/fx 1.32.0 → 2.0.0-beta.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 (881) hide show
  1. package/README.md +367 -2
  2. package/dist/Fx/Fx.d.ts +96 -0
  3. package/dist/Fx/Fx.d.ts.map +1 -0
  4. package/dist/Fx/Fx.js +35 -0
  5. package/dist/Fx/TypeId.d.ts +20 -0
  6. package/dist/Fx/TypeId.d.ts.map +1 -0
  7. package/dist/Fx/TypeId.js +15 -0
  8. package/dist/Fx/combinators/additive.d.ts +94 -0
  9. package/dist/Fx/combinators/additive.d.ts.map +1 -0
  10. package/dist/Fx/combinators/additive.js +92 -0
  11. package/dist/Fx/combinators/catch.d.ts +114 -0
  12. package/dist/Fx/combinators/catch.d.ts.map +1 -0
  13. package/dist/Fx/combinators/catch.js +123 -0
  14. package/dist/Fx/combinators/causes.d.ts +12 -0
  15. package/dist/Fx/combinators/causes.d.ts.map +1 -0
  16. package/dist/Fx/combinators/causes.js +16 -0
  17. package/dist/Fx/combinators/changesWithEffect.d.ts +20 -0
  18. package/dist/Fx/combinators/changesWithEffect.d.ts.map +1 -0
  19. package/dist/Fx/combinators/changesWithEffect.js +28 -0
  20. package/dist/Fx/combinators/compact.d.ts +12 -0
  21. package/dist/Fx/combinators/compact.d.ts.map +1 -0
  22. package/dist/Fx/combinators/compact.js +11 -0
  23. package/dist/Fx/combinators/continueWith.d.ts +51 -0
  24. package/dist/Fx/combinators/continueWith.d.ts.map +1 -0
  25. package/dist/Fx/combinators/continueWith.js +41 -0
  26. package/dist/Fx/combinators/dropUntil.d.ts +29 -0
  27. package/dist/Fx/combinators/dropUntil.d.ts.map +1 -0
  28. package/dist/Fx/combinators/dropUntil.js +23 -0
  29. package/dist/Fx/combinators/ensuring.d.ts +16 -0
  30. package/dist/Fx/combinators/ensuring.d.ts.map +1 -0
  31. package/dist/Fx/combinators/ensuring.js +13 -0
  32. package/dist/Fx/combinators/exhaustLatestMap.d.ts +15 -0
  33. package/dist/Fx/combinators/exhaustLatestMap.d.ts.map +1 -0
  34. package/dist/Fx/combinators/exhaustLatestMap.js +48 -0
  35. package/dist/Fx/combinators/exhaustLatestMapEffect.d.ts +13 -0
  36. package/dist/Fx/combinators/exhaustLatestMapEffect.d.ts.map +1 -0
  37. package/dist/Fx/combinators/exhaustLatestMapEffect.js +14 -0
  38. package/dist/Fx/combinators/exhaustMap.d.ts +11 -0
  39. package/dist/Fx/combinators/exhaustMap.d.ts.map +1 -0
  40. package/dist/Fx/combinators/exhaustMap.js +19 -0
  41. package/dist/Fx/combinators/exhaustMapEffect.d.ts +11 -0
  42. package/dist/Fx/combinators/exhaustMapEffect.d.ts.map +1 -0
  43. package/dist/Fx/combinators/exhaustMapEffect.js +12 -0
  44. package/dist/Fx/combinators/exit.d.ts +12 -0
  45. package/dist/Fx/combinators/exit.d.ts.map +1 -0
  46. package/dist/Fx/combinators/exit.js +11 -0
  47. package/dist/Fx/combinators/filter.d.ts +14 -0
  48. package/dist/Fx/combinators/filter.d.ts.map +1 -0
  49. package/dist/Fx/combinators/filter.js +12 -0
  50. package/dist/Fx/combinators/filterEffect.d.ts +15 -0
  51. package/dist/Fx/combinators/filterEffect.d.ts.map +1 -0
  52. package/dist/Fx/combinators/filterEffect.js +12 -0
  53. package/dist/Fx/combinators/filterMap.d.ts +15 -0
  54. package/dist/Fx/combinators/filterMap.d.ts.map +1 -0
  55. package/dist/Fx/combinators/filterMap.js +12 -0
  56. package/dist/Fx/combinators/filterMapEffect.d.ts +16 -0
  57. package/dist/Fx/combinators/filterMapEffect.d.ts.map +1 -0
  58. package/dist/Fx/combinators/filterMapEffect.js +12 -0
  59. package/dist/Fx/combinators/filterMapLoop.d.ts +17 -0
  60. package/dist/Fx/combinators/filterMapLoop.d.ts.map +1 -0
  61. package/dist/Fx/combinators/filterMapLoop.js +14 -0
  62. package/dist/Fx/combinators/filterMapLoopCause.d.ts +18 -0
  63. package/dist/Fx/combinators/filterMapLoopCause.d.ts.map +1 -0
  64. package/dist/Fx/combinators/filterMapLoopCause.js +14 -0
  65. package/dist/Fx/combinators/filterMapLoopCauseEffect.d.ts +18 -0
  66. package/dist/Fx/combinators/filterMapLoopCauseEffect.d.ts.map +1 -0
  67. package/dist/Fx/combinators/filterMapLoopCauseEffect.js +13 -0
  68. package/dist/Fx/combinators/filterMapLoopEffect.d.ts +17 -0
  69. package/dist/Fx/combinators/filterMapLoopEffect.d.ts.map +1 -0
  70. package/dist/Fx/combinators/filterMapLoopEffect.js +13 -0
  71. package/dist/Fx/combinators/flatMap.d.ts +23 -0
  72. package/dist/Fx/combinators/flatMap.d.ts.map +1 -0
  73. package/dist/Fx/combinators/flatMap.js +21 -0
  74. package/dist/Fx/combinators/flatMapConcurrently.d.ts +12 -0
  75. package/dist/Fx/combinators/flatMapConcurrently.d.ts.map +1 -0
  76. package/dist/Fx/combinators/flatMapConcurrently.js +23 -0
  77. package/dist/Fx/combinators/flatMapConcurrentlyEffect.d.ts +12 -0
  78. package/dist/Fx/combinators/flatMapConcurrentlyEffect.d.ts.map +1 -0
  79. package/dist/Fx/combinators/flatMapConcurrentlyEffect.js +13 -0
  80. package/dist/Fx/combinators/flatMapEffect.d.ts +24 -0
  81. package/dist/Fx/combinators/flatMapEffect.d.ts.map +1 -0
  82. package/dist/Fx/combinators/flatMapEffect.js +14 -0
  83. package/dist/Fx/combinators/flip.d.ts +11 -0
  84. package/dist/Fx/combinators/flip.d.ts.map +1 -0
  85. package/dist/Fx/combinators/flip.js +11 -0
  86. package/dist/Fx/combinators/gen.d.ts +20 -0
  87. package/dist/Fx/combinators/gen.d.ts.map +1 -0
  88. package/dist/Fx/combinators/gen.js +14 -0
  89. package/dist/Fx/combinators/genScoped.d.ts +20 -0
  90. package/dist/Fx/combinators/genScoped.d.ts.map +1 -0
  91. package/dist/Fx/combinators/genScoped.js +13 -0
  92. package/dist/Fx/combinators/index.d.ts +62 -0
  93. package/dist/Fx/combinators/index.d.ts.map +1 -0
  94. package/dist/Fx/combinators/index.js +61 -0
  95. package/dist/Fx/combinators/keyed.d.ts +44 -0
  96. package/dist/Fx/combinators/keyed.d.ts.map +1 -0
  97. package/dist/Fx/combinators/keyed.js +199 -0
  98. package/dist/Fx/combinators/loop.d.ts +16 -0
  99. package/dist/Fx/combinators/loop.d.ts.map +1 -0
  100. package/dist/Fx/combinators/loop.js +14 -0
  101. package/dist/Fx/combinators/loopCause.d.ts +16 -0
  102. package/dist/Fx/combinators/loopCause.d.ts.map +1 -0
  103. package/dist/Fx/combinators/loopCause.js +13 -0
  104. package/dist/Fx/combinators/loopCauseEffect.d.ts +17 -0
  105. package/dist/Fx/combinators/loopCauseEffect.d.ts.map +1 -0
  106. package/dist/Fx/combinators/loopCauseEffect.js +13 -0
  107. package/dist/Fx/combinators/loopEffect.d.ts +16 -0
  108. package/dist/Fx/combinators/loopEffect.d.ts.map +1 -0
  109. package/dist/Fx/combinators/loopEffect.js +13 -0
  110. package/dist/Fx/combinators/map.d.ts +14 -0
  111. package/dist/Fx/combinators/map.d.ts.map +1 -0
  112. package/dist/Fx/combinators/map.js +12 -0
  113. package/dist/Fx/combinators/mapBoth.d.ts +21 -0
  114. package/dist/Fx/combinators/mapBoth.d.ts.map +1 -0
  115. package/dist/Fx/combinators/mapBoth.js +14 -0
  116. package/dist/Fx/combinators/mapEffect.d.ts +15 -0
  117. package/dist/Fx/combinators/mapEffect.d.ts.map +1 -0
  118. package/dist/Fx/combinators/mapEffect.js +12 -0
  119. package/dist/Fx/combinators/mapError.d.ts +17 -0
  120. package/dist/Fx/combinators/mapError.d.ts.map +1 -0
  121. package/dist/Fx/combinators/mapError.js +16 -0
  122. package/dist/Fx/combinators/mergeAll.d.ts +11 -0
  123. package/dist/Fx/combinators/mergeAll.d.ts.map +1 -0
  124. package/dist/Fx/combinators/mergeAll.js +15 -0
  125. package/dist/Fx/combinators/mergeOrdered.d.ts +14 -0
  126. package/dist/Fx/combinators/mergeOrdered.d.ts.map +1 -0
  127. package/dist/Fx/combinators/mergeOrdered.js +89 -0
  128. package/dist/Fx/combinators/onError.d.ts +17 -0
  129. package/dist/Fx/combinators/onError.d.ts.map +1 -0
  130. package/dist/Fx/combinators/onError.js +14 -0
  131. package/dist/Fx/combinators/onExit.d.ts +16 -0
  132. package/dist/Fx/combinators/onExit.d.ts.map +1 -0
  133. package/dist/Fx/combinators/onExit.js +39 -0
  134. package/dist/Fx/combinators/onInterrupt.d.ts +16 -0
  135. package/dist/Fx/combinators/onInterrupt.d.ts.map +1 -0
  136. package/dist/Fx/combinators/onInterrupt.js +38 -0
  137. package/dist/Fx/combinators/provide.d.ts +56 -0
  138. package/dist/Fx/combinators/provide.d.ts.map +1 -0
  139. package/dist/Fx/combinators/provide.js +54 -0
  140. package/dist/Fx/combinators/result.d.ts +23 -0
  141. package/dist/Fx/combinators/result.d.ts.map +1 -0
  142. package/dist/Fx/combinators/result.js +32 -0
  143. package/dist/Fx/combinators/scan.d.ts +33 -0
  144. package/dist/Fx/combinators/scan.d.ts.map +1 -0
  145. package/dist/Fx/combinators/scan.js +38 -0
  146. package/dist/Fx/combinators/skip.d.ts +27 -0
  147. package/dist/Fx/combinators/skip.d.ts.map +1 -0
  148. package/dist/Fx/combinators/skip.js +22 -0
  149. package/dist/Fx/combinators/skipRepeats.d.ts +11 -0
  150. package/dist/Fx/combinators/skipRepeats.d.ts.map +1 -0
  151. package/dist/Fx/combinators/skipRepeats.js +12 -0
  152. package/dist/Fx/combinators/skipRepeatsWith.d.ts +12 -0
  153. package/dist/Fx/combinators/skipRepeatsWith.d.ts.map +1 -0
  154. package/dist/Fx/combinators/skipRepeatsWith.js +20 -0
  155. package/dist/Fx/combinators/skipWhile.d.ts +49 -0
  156. package/dist/Fx/combinators/skipWhile.d.ts.map +1 -0
  157. package/dist/Fx/combinators/skipWhile.js +66 -0
  158. package/dist/Fx/combinators/slice.d.ts +36 -0
  159. package/dist/Fx/combinators/slice.d.ts.map +1 -0
  160. package/dist/Fx/combinators/slice.js +23 -0
  161. package/dist/Fx/combinators/switchMap.d.ts +13 -0
  162. package/dist/Fx/combinators/switchMap.d.ts.map +1 -0
  163. package/dist/Fx/combinators/switchMap.js +33 -0
  164. package/dist/Fx/combinators/switchMapEffect.d.ts +13 -0
  165. package/dist/Fx/combinators/switchMapEffect.d.ts.map +1 -0
  166. package/dist/Fx/combinators/switchMapEffect.js +14 -0
  167. package/dist/Fx/combinators/take.d.ts +27 -0
  168. package/dist/Fx/combinators/take.d.ts.map +1 -0
  169. package/dist/Fx/combinators/take.js +22 -0
  170. package/dist/Fx/combinators/takeUntil.d.ts +42 -0
  171. package/dist/Fx/combinators/takeUntil.d.ts.map +1 -0
  172. package/dist/Fx/combinators/takeUntil.js +45 -0
  173. package/dist/Fx/combinators/takeWhile.d.ts +29 -0
  174. package/dist/Fx/combinators/takeWhile.d.ts.map +1 -0
  175. package/dist/Fx/combinators/takeWhile.js +23 -0
  176. package/dist/Fx/combinators/tapEffect.d.ts +15 -0
  177. package/dist/Fx/combinators/tapEffect.d.ts.map +1 -0
  178. package/dist/Fx/combinators/tapEffect.js +18 -0
  179. package/dist/Fx/combinators/tuple.d.ts +27 -0
  180. package/dist/Fx/combinators/tuple.d.ts.map +1 -0
  181. package/dist/Fx/combinators/tuple.js +46 -0
  182. package/dist/Fx/combinators/unwrap.d.ts +12 -0
  183. package/dist/Fx/combinators/unwrap.d.ts.map +1 -0
  184. package/dist/Fx/combinators/unwrap.js +14 -0
  185. package/dist/Fx/combinators/unwrapScoped.d.ts +15 -0
  186. package/dist/Fx/combinators/unwrapScoped.d.ts.map +1 -0
  187. package/dist/Fx/combinators/unwrapScoped.js +16 -0
  188. package/dist/Fx/combinators/when.d.ts +36 -0
  189. package/dist/Fx/combinators/when.d.ts.map +1 -0
  190. package/dist/Fx/combinators/when.js +28 -0
  191. package/dist/Fx/combinators/withSpan.d.ts +4 -0
  192. package/dist/Fx/combinators/withSpan.d.ts.map +1 -0
  193. package/dist/Fx/combinators/withSpan.js +6 -0
  194. package/dist/Fx/combinators/zip.d.ts +75 -0
  195. package/dist/Fx/combinators/zip.d.ts.map +1 -0
  196. package/dist/Fx/combinators/zip.js +100 -0
  197. package/dist/Fx/constructors/at.d.ts +16 -0
  198. package/dist/Fx/constructors/at.d.ts.map +1 -0
  199. package/dist/Fx/constructors/at.js +13 -0
  200. package/dist/Fx/constructors/die.d.ts +11 -0
  201. package/dist/Fx/constructors/die.d.ts.map +1 -0
  202. package/dist/Fx/constructors/die.js +12 -0
  203. package/dist/Fx/constructors/empty.d.ts +8 -0
  204. package/dist/Fx/constructors/empty.d.ts.map +1 -0
  205. package/dist/Fx/constructors/empty.js +8 -0
  206. package/dist/Fx/constructors/fail.d.ts +11 -0
  207. package/dist/Fx/constructors/fail.d.ts.map +1 -0
  208. package/dist/Fx/constructors/fail.js +12 -0
  209. package/dist/Fx/constructors/failCause.d.ts +12 -0
  210. package/dist/Fx/constructors/failCause.d.ts.map +1 -0
  211. package/dist/Fx/constructors/failCause.js +11 -0
  212. package/dist/Fx/constructors/fn.d.ts +47 -0
  213. package/dist/Fx/constructors/fn.d.ts.map +1 -0
  214. package/dist/Fx/constructors/fn.js +23 -0
  215. package/dist/Fx/constructors/fromEffect.d.ts +21 -0
  216. package/dist/Fx/constructors/fromEffect.d.ts.map +1 -0
  217. package/dist/Fx/constructors/fromEffect.js +21 -0
  218. package/dist/Fx/constructors/fromFailures.d.ts +10 -0
  219. package/dist/Fx/constructors/fromFailures.d.ts.map +1 -0
  220. package/dist/Fx/constructors/fromFailures.js +13 -0
  221. package/dist/Fx/constructors/fromIterable.d.ts +12 -0
  222. package/dist/Fx/constructors/fromIterable.d.ts.map +1 -0
  223. package/dist/Fx/constructors/fromIterable.js +12 -0
  224. package/dist/Fx/constructors/fromSchedule.d.ts +13 -0
  225. package/dist/Fx/constructors/fromSchedule.d.ts.map +1 -0
  226. package/dist/Fx/constructors/fromSchedule.js +13 -0
  227. package/dist/Fx/constructors/fromYieldable.d.ts +12 -0
  228. package/dist/Fx/constructors/fromYieldable.d.ts.map +1 -0
  229. package/dist/Fx/constructors/fromYieldable.js +12 -0
  230. package/dist/Fx/constructors/index.d.ts +16 -0
  231. package/dist/Fx/constructors/index.d.ts.map +1 -0
  232. package/dist/Fx/constructors/index.js +15 -0
  233. package/dist/Fx/constructors/interrupt.d.ts +10 -0
  234. package/dist/Fx/constructors/interrupt.d.ts.map +1 -0
  235. package/dist/Fx/constructors/interrupt.js +12 -0
  236. package/dist/Fx/constructors/make.d.ts +40 -0
  237. package/dist/Fx/constructors/make.d.ts.map +1 -0
  238. package/dist/Fx/constructors/make.js +61 -0
  239. package/dist/Fx/constructors/periodic.d.ts +12 -0
  240. package/dist/Fx/constructors/periodic.d.ts.map +1 -0
  241. package/dist/Fx/constructors/periodic.js +12 -0
  242. package/dist/Fx/constructors/succeed.d.ts +32 -0
  243. package/dist/Fx/constructors/succeed.d.ts.map +1 -0
  244. package/dist/Fx/constructors/succeed.js +32 -0
  245. package/dist/Fx/constructors/suspend.d.ts +3 -0
  246. package/dist/Fx/constructors/suspend.d.ts.map +1 -0
  247. package/dist/Fx/constructors/suspend.js +3 -0
  248. package/dist/Fx/index.d.ts +7 -0
  249. package/dist/Fx/index.d.ts.map +1 -0
  250. package/dist/Fx/index.js +6 -0
  251. package/dist/Fx/internal/DeferredRef.d.ts +29 -0
  252. package/dist/Fx/internal/DeferredRef.d.ts.map +1 -0
  253. package/dist/Fx/internal/DeferredRef.js +63 -0
  254. package/dist/Fx/internal/UnionToTuple.d.ts.map +1 -0
  255. package/dist/Fx/internal/UnionToTuple.js +1 -0
  256. package/dist/Fx/internal/diff.d.ts +44 -0
  257. package/dist/Fx/internal/diff.d.ts.map +1 -0
  258. package/dist/Fx/internal/diff.js +106 -0
  259. package/dist/Fx/internal/equivalence.d.ts +4 -0
  260. package/dist/Fx/internal/equivalence.d.ts.map +1 -0
  261. package/dist/Fx/internal/equivalence.js +10 -0
  262. package/dist/Fx/internal/multicast.d.ts +10 -0
  263. package/dist/Fx/internal/multicast.d.ts.map +1 -0
  264. package/dist/Fx/internal/multicast.js +32 -0
  265. package/dist/Fx/internal/ring-buffer.d.ts +14 -0
  266. package/dist/Fx/internal/ring-buffer.d.ts.map +1 -0
  267. package/dist/Fx/internal/ring-buffer.js +52 -0
  268. package/dist/Fx/internal/scope.d.ts +11 -0
  269. package/dist/Fx/internal/scope.d.ts.map +1 -0
  270. package/dist/Fx/internal/scope.js +12 -0
  271. package/dist/Fx/internal/yieldable.d.ts +17 -0
  272. package/dist/Fx/internal/yieldable.d.ts.map +1 -0
  273. package/dist/Fx/internal/yieldable.js +20 -0
  274. package/dist/Fx/run/collect.d.ts +45 -0
  275. package/dist/Fx/run/collect.d.ts.map +1 -0
  276. package/dist/Fx/run/collect.js +51 -0
  277. package/dist/Fx/run/first.d.ts +14 -0
  278. package/dist/Fx/run/first.d.ts.map +1 -0
  279. package/dist/Fx/run/first.js +16 -0
  280. package/dist/Fx/run/fork.d.ts +29 -0
  281. package/dist/Fx/run/fork.d.ts.map +1 -0
  282. package/dist/Fx/run/fork.js +27 -0
  283. package/dist/Fx/run/index.d.ts +6 -0
  284. package/dist/Fx/run/index.d.ts.map +1 -0
  285. package/dist/Fx/run/index.js +5 -0
  286. package/dist/Fx/run/observe.d.ts +53 -0
  287. package/dist/Fx/run/observe.d.ts.map +1 -0
  288. package/dist/Fx/run/observe.js +55 -0
  289. package/dist/Fx/run/runPromise.d.ts +25 -0
  290. package/dist/Fx/run/runPromise.d.ts.map +1 -0
  291. package/dist/Fx/run/runPromise.js +23 -0
  292. package/dist/Fx/stream.d.ts +7 -0
  293. package/dist/Fx/stream.d.ts.map +1 -0
  294. package/dist/Fx/stream.js +7 -0
  295. package/dist/Fx.d.ts +2 -0
  296. package/dist/Fx.d.ts.map +1 -0
  297. package/dist/Fx.js +1 -0
  298. package/dist/Push/Push.d.ts +375 -0
  299. package/dist/Push/Push.d.ts.map +1 -0
  300. package/dist/Push/Push.js +346 -0
  301. package/dist/Push/index.d.ts +2 -0
  302. package/dist/Push/index.d.ts.map +1 -0
  303. package/dist/Push/index.js +1 -0
  304. package/dist/Push.d.ts +2 -0
  305. package/dist/Push.d.ts.map +1 -0
  306. package/dist/Push.js +1 -0
  307. package/dist/RefSubject/RefArray.d.ts +328 -0
  308. package/dist/RefSubject/RefArray.d.ts.map +1 -0
  309. package/dist/RefSubject/RefArray.js +302 -0
  310. package/dist/RefSubject/RefBigDecimal.d.ts +183 -0
  311. package/dist/RefSubject/RefBigDecimal.d.ts.map +1 -0
  312. package/dist/RefSubject/RefBigDecimal.js +161 -0
  313. package/dist/RefSubject/RefBigInt.d.ts +138 -0
  314. package/dist/RefSubject/RefBigInt.d.ts.map +1 -0
  315. package/dist/RefSubject/RefBigInt.js +126 -0
  316. package/dist/RefSubject/RefBoolean.d.ts +135 -0
  317. package/dist/RefSubject/RefBoolean.d.ts.map +1 -0
  318. package/dist/RefSubject/RefBoolean.js +124 -0
  319. package/dist/RefSubject/RefCause.d.ts +100 -0
  320. package/dist/RefSubject/RefCause.d.ts.map +1 -0
  321. package/dist/RefSubject/RefCause.js +93 -0
  322. package/dist/RefSubject/RefChunk.d.ts +316 -0
  323. package/dist/RefSubject/RefChunk.d.ts.map +1 -0
  324. package/dist/RefSubject/RefChunk.js +286 -0
  325. package/dist/RefSubject/RefDateTime.d.ts +155 -0
  326. package/dist/RefSubject/RefDateTime.d.ts.map +1 -0
  327. package/dist/RefSubject/RefDateTime.js +101 -0
  328. package/dist/RefSubject/RefDuration.d.ts +126 -0
  329. package/dist/RefSubject/RefDuration.d.ts.map +1 -0
  330. package/dist/RefSubject/RefDuration.js +115 -0
  331. package/dist/RefSubject/RefGraph.d.ts +239 -0
  332. package/dist/RefSubject/RefGraph.d.ts.map +1 -0
  333. package/dist/RefSubject/RefGraph.js +272 -0
  334. package/dist/RefSubject/RefHashMap.d.ts +228 -0
  335. package/dist/RefSubject/RefHashMap.d.ts.map +1 -0
  336. package/dist/RefSubject/RefHashMap.js +212 -0
  337. package/dist/RefSubject/RefHashRing.d.ts +123 -0
  338. package/dist/RefSubject/RefHashRing.d.ts.map +1 -0
  339. package/dist/RefSubject/RefHashRing.js +115 -0
  340. package/dist/RefSubject/RefHashSet.d.ts +179 -0
  341. package/dist/RefSubject/RefHashSet.d.ts.map +1 -0
  342. package/dist/RefSubject/RefHashSet.js +164 -0
  343. package/dist/RefSubject/RefIterable.d.ts +257 -0
  344. package/dist/RefSubject/RefIterable.d.ts.map +1 -0
  345. package/dist/RefSubject/RefIterable.js +237 -0
  346. package/dist/RefSubject/RefOption.d.ts +124 -0
  347. package/dist/RefSubject/RefOption.d.ts.map +1 -0
  348. package/dist/RefSubject/RefOption.js +115 -0
  349. package/dist/RefSubject/RefRecord.d.ts +264 -0
  350. package/dist/RefSubject/RefRecord.d.ts.map +1 -0
  351. package/dist/RefSubject/RefRecord.js +249 -0
  352. package/dist/RefSubject/RefResult.d.ts +121 -0
  353. package/dist/RefSubject/RefResult.d.ts.map +1 -0
  354. package/dist/RefSubject/RefResult.js +107 -0
  355. package/dist/RefSubject/RefString.d.ts +147 -0
  356. package/dist/RefSubject/RefString.d.ts.map +1 -0
  357. package/dist/RefSubject/RefString.js +137 -0
  358. package/dist/RefSubject/RefStruct.d.ts +123 -0
  359. package/dist/RefSubject/RefStruct.d.ts.map +1 -0
  360. package/dist/RefSubject/RefStruct.js +113 -0
  361. package/dist/RefSubject/RefSubject.d.ts +1057 -0
  362. package/dist/RefSubject/RefSubject.d.ts.map +1 -0
  363. package/dist/RefSubject/RefSubject.js +1389 -0
  364. package/dist/RefSubject/RefTrie.d.ts +216 -0
  365. package/dist/RefSubject/RefTrie.d.ts.map +1 -0
  366. package/dist/RefSubject/RefTrie.js +201 -0
  367. package/dist/RefSubject/RefTuple.d.ts +107 -0
  368. package/dist/RefSubject/RefTuple.d.ts.map +1 -0
  369. package/dist/RefSubject/RefTuple.js +94 -0
  370. package/dist/RefSubject/index.d.ts +22 -0
  371. package/dist/RefSubject/index.d.ts.map +1 -0
  372. package/dist/RefSubject/index.js +21 -0
  373. package/dist/RefSubject.d.ts +2 -0
  374. package/dist/RefSubject.d.ts.map +1 -0
  375. package/dist/RefSubject.js +1 -0
  376. package/dist/Sink/Sink.d.ts +94 -0
  377. package/dist/Sink/Sink.d.ts.map +1 -0
  378. package/dist/Sink/Sink.js +34 -0
  379. package/dist/Sink/combinators.d.ts +228 -0
  380. package/dist/Sink/combinators.d.ts.map +1 -0
  381. package/dist/Sink/combinators.js +689 -0
  382. package/dist/Sink/index.d.ts +3 -0
  383. package/dist/Sink/index.d.ts.map +1 -0
  384. package/dist/Sink/index.js +2 -0
  385. package/dist/Sink.d.ts +2 -0
  386. package/dist/Sink.d.ts.map +1 -0
  387. package/dist/Sink.js +1 -0
  388. package/dist/Subject/Subject.d.ts +152 -0
  389. package/dist/Subject/Subject.d.ts.map +1 -0
  390. package/dist/Subject/Subject.js +272 -0
  391. package/dist/Subject/index.d.ts +2 -0
  392. package/dist/Subject/index.d.ts.map +1 -0
  393. package/dist/Subject/index.js +1 -0
  394. package/dist/Subject.d.ts +2 -0
  395. package/dist/Subject.d.ts.map +1 -0
  396. package/dist/Subject.js +1 -0
  397. package/dist/Versioned/Versioned.d.ts +206 -0
  398. package/dist/Versioned/Versioned.d.ts.map +1 -0
  399. package/dist/Versioned/Versioned.js +246 -0
  400. package/dist/Versioned/index.d.ts +2 -0
  401. package/dist/Versioned/index.d.ts.map +1 -0
  402. package/dist/Versioned/index.js +1 -0
  403. package/dist/Versioned.d.ts +2 -0
  404. package/dist/Versioned.d.ts.map +1 -0
  405. package/dist/Versioned.js +1 -0
  406. package/dist/index.d.ts +8 -0
  407. package/dist/index.d.ts.map +1 -0
  408. package/dist/index.js +7 -0
  409. package/package.json +26 -195
  410. package/src/Fx/Fx.ts +164 -0
  411. package/src/Fx/TypeId.ts +25 -0
  412. package/src/Fx/combinators/additive.ts +142 -0
  413. package/src/Fx/combinators/catch.ts +421 -0
  414. package/src/Fx/combinators/causes.ts +23 -0
  415. package/src/Fx/combinators/changesWithEffect.ts +66 -0
  416. package/src/Fx/combinators/compact.ts +15 -0
  417. package/src/Fx/combinators/continueWith.ts +78 -0
  418. package/src/Fx/combinators/dropUntil.ts +47 -0
  419. package/src/Fx/combinators/ensuring.ts +23 -0
  420. package/src/Fx/combinators/exhaustLatestMap.ts +74 -0
  421. package/src/Fx/combinators/exhaustLatestMapEffect.ts +25 -0
  422. package/src/Fx/combinators/exhaustMap.ts +36 -0
  423. package/src/Fx/combinators/exhaustMapEffect.ts +23 -0
  424. package/src/Fx/combinators/exit.ts +15 -0
  425. package/src/Fx/combinators/filter.ts +22 -0
  426. package/src/Fx/combinators/filterEffect.ts +31 -0
  427. package/src/Fx/combinators/filterMap.ts +23 -0
  428. package/src/Fx/combinators/filterMapEffect.ts +32 -0
  429. package/src/Fx/combinators/filterMapLoop.ts +35 -0
  430. package/src/Fx/combinators/filterMapLoopCause.ts +36 -0
  431. package/src/Fx/combinators/filterMapLoopCauseEffect.ts +46 -0
  432. package/src/Fx/combinators/filterMapLoopEffect.ts +36 -0
  433. package/src/Fx/combinators/flatMap.ts +51 -0
  434. package/src/Fx/combinators/flatMapConcurrently.ts +39 -0
  435. package/src/Fx/combinators/flatMapConcurrentlyEffect.ts +26 -0
  436. package/src/Fx/combinators/flatMapEffect.ts +42 -0
  437. package/src/Fx/combinators/flip.ts +14 -0
  438. package/src/Fx/combinators/gen.ts +24 -0
  439. package/src/Fx/combinators/genScoped.ts +24 -0
  440. package/src/Fx/combinators/index.ts +61 -0
  441. package/src/Fx/combinators/keyed.ts +369 -0
  442. package/src/Fx/combinators/loop.ts +27 -0
  443. package/src/Fx/combinators/loopCause.ts +34 -0
  444. package/src/Fx/combinators/loopCauseEffect.ts +36 -0
  445. package/src/Fx/combinators/loopEffect.ts +34 -0
  446. package/src/Fx/combinators/map.ts +22 -0
  447. package/src/Fx/combinators/mapBoth.ts +40 -0
  448. package/src/Fx/combinators/mapEffect.ts +32 -0
  449. package/src/Fx/combinators/mapError.ts +28 -0
  450. package/src/Fx/combinators/mergeAll.ts +22 -0
  451. package/src/Fx/combinators/mergeOrdered.ts +123 -0
  452. package/src/Fx/combinators/onError.ts +40 -0
  453. package/src/Fx/combinators/onExit.ts +82 -0
  454. package/src/Fx/combinators/onInterrupt.ts +87 -0
  455. package/src/Fx/combinators/provide.ts +124 -0
  456. package/src/Fx/combinators/result.ts +39 -0
  457. package/src/Fx/combinators/scan.ts +82 -0
  458. package/src/Fx/combinators/skip.ts +41 -0
  459. package/src/Fx/combinators/skipRepeats.ts +15 -0
  460. package/src/Fx/combinators/skipRepeatsWith.ts +40 -0
  461. package/src/Fx/combinators/skipWhile.ts +100 -0
  462. package/src/Fx/combinators/slice.ts +55 -0
  463. package/src/Fx/combinators/switchMap.ts +55 -0
  464. package/src/Fx/combinators/switchMapEffect.ts +25 -0
  465. package/src/Fx/combinators/take.ts +38 -0
  466. package/src/Fx/combinators/takeUntil.ts +88 -0
  467. package/src/Fx/combinators/takeWhile.ts +47 -0
  468. package/src/Fx/combinators/tapEffect.ts +39 -0
  469. package/src/Fx/combinators/tuple.ts +79 -0
  470. package/src/Fx/combinators/unwrap.ts +21 -0
  471. package/src/Fx/combinators/unwrapScoped.ts +26 -0
  472. package/src/Fx/combinators/when.ts +64 -0
  473. package/src/Fx/combinators/withSpan.ts +24 -0
  474. package/src/Fx/combinators/zip.ts +175 -0
  475. package/src/Fx/constructors/at.ts +23 -0
  476. package/src/Fx/constructors/die.ts +17 -0
  477. package/src/Fx/constructors/empty.ts +10 -0
  478. package/src/Fx/constructors/fail.ts +14 -0
  479. package/src/Fx/constructors/failCause.ts +14 -0
  480. package/src/Fx/constructors/fn.ts +245 -0
  481. package/src/Fx/constructors/fromEffect.ts +24 -0
  482. package/src/Fx/constructors/fromFailures.ts +19 -0
  483. package/src/Fx/constructors/fromIterable.ts +15 -0
  484. package/src/Fx/constructors/fromSchedule.ts +18 -0
  485. package/src/Fx/constructors/fromYieldable.ts +17 -0
  486. package/src/Fx/constructors/index.ts +15 -0
  487. package/src/Fx/constructors/interrupt.ts +13 -0
  488. package/src/Fx/constructors/make.ts +103 -0
  489. package/src/Fx/constructors/periodic.ts +15 -0
  490. package/src/Fx/constructors/succeed.ts +37 -0
  491. package/src/Fx/constructors/suspend.ts +6 -0
  492. package/src/Fx/index.ts +6 -0
  493. package/src/Fx/internal/DeferredRef.ts +87 -0
  494. package/src/Fx/internal/UnionToTuple.ts +12 -0
  495. package/src/Fx/internal/diff.ts +191 -0
  496. package/src/Fx/internal/equivalence.ts +12 -0
  497. package/src/Fx/internal/multicast.ts +51 -0
  498. package/src/Fx/internal/ring-buffer.ts +60 -0
  499. package/src/Fx/internal/scope.ts +58 -0
  500. package/src/Fx/internal/yieldable.ts +31 -0
  501. package/src/Fx/run/collect.ts +79 -0
  502. package/src/Fx/run/first.ts +20 -0
  503. package/src/Fx/run/fork.ts +40 -0
  504. package/src/Fx/run/index.ts +5 -0
  505. package/src/Fx/run/observe.ts +114 -0
  506. package/src/Fx/run/runPromise.ts +32 -0
  507. package/src/Fx/stream.ts +42 -0
  508. package/src/Fx.additive-combinators.test.ts +126 -0
  509. package/src/Fx.catch-additive.test.ts +206 -0
  510. package/src/Fx.catch.test.ts +60 -0
  511. package/src/Fx.dropUntil.test.ts +61 -0
  512. package/src/Fx.fn.test.ts +51 -0
  513. package/src/Fx.lifecycle.test.ts +79 -0
  514. package/src/Fx.mapError-mapBoth.test.ts +101 -0
  515. package/src/Fx.provide-combinators.test.ts +94 -0
  516. package/src/Fx.result-changesWithEffect.test.ts +112 -0
  517. package/src/Fx.scan.test.ts +73 -0
  518. package/src/Fx.takeWhile-skipWhile.test.ts +84 -0
  519. package/src/Fx.test.ts +71 -0
  520. package/src/Fx.ts +1 -2591
  521. package/src/Fx.zip-merge-additive.test.ts +171 -0
  522. package/src/Fx.zip.test.ts +133 -0
  523. package/src/Push/Push.ts +1072 -0
  524. package/src/Push/index.ts +1 -0
  525. package/src/Push.additive.test.ts +256 -0
  526. package/src/Push.test.ts +26 -0
  527. package/src/Push.ts +1 -480
  528. package/src/RefSubject/RefArray.ts +512 -0
  529. package/src/RefSubject/RefBigDecimal.test.ts +56 -0
  530. package/src/RefSubject/RefBigDecimal.ts +295 -0
  531. package/src/RefSubject/RefBigInt.test.ts +56 -0
  532. package/src/RefSubject/RefBigInt.ts +189 -0
  533. package/src/RefSubject/RefBoolean.test.ts +57 -0
  534. package/src/RefSubject/RefBoolean.ts +185 -0
  535. package/src/RefSubject/RefCause.test.ts +53 -0
  536. package/src/RefSubject/RefCause.ts +146 -0
  537. package/src/RefSubject/RefChunk.ts +510 -0
  538. package/src/RefSubject/RefDateTime.test.ts +43 -0
  539. package/src/RefSubject/RefDateTime.ts +264 -0
  540. package/src/RefSubject/RefDuration.test.ts +49 -0
  541. package/src/RefSubject/RefDuration.ts +188 -0
  542. package/src/RefSubject/RefGraph.ts +650 -0
  543. package/src/RefSubject/RefHashMap.ts +465 -0
  544. package/src/RefSubject/RefHashRing.ts +262 -0
  545. package/src/RefSubject/RefHashSet.ts +308 -0
  546. package/src/RefSubject/RefIterable.ts +445 -0
  547. package/src/RefSubject/RefOption.test.ts +67 -0
  548. package/src/RefSubject/RefOption.ts +193 -0
  549. package/src/RefSubject/RefRecord.ts +612 -0
  550. package/src/RefSubject/RefResult.test.ts +63 -0
  551. package/src/RefSubject/RefResult.ts +209 -0
  552. package/src/RefSubject/RefString.test.ts +61 -0
  553. package/src/RefSubject/RefString.ts +256 -0
  554. package/src/RefSubject/RefStruct.test.ts +60 -0
  555. package/src/RefSubject/RefStruct.ts +253 -0
  556. package/src/RefSubject/RefSubject.ts +2646 -0
  557. package/src/RefSubject/RefTrie.ts +356 -0
  558. package/src/RefSubject/RefTuple.test.ts +60 -0
  559. package/src/RefSubject/RefTuple.ts +231 -0
  560. package/src/RefSubject/index.ts +21 -0
  561. package/src/RefSubject.additive-parity.test.ts +101 -0
  562. package/src/RefSubject.test.ts +65 -0
  563. package/src/RefSubject.ts +1 -2488
  564. package/src/Sink/Sink.ts +159 -0
  565. package/src/Sink/combinators.ts +1115 -0
  566. package/src/Sink/index.ts +2 -0
  567. package/src/Sink.combinators.test.ts +88 -0
  568. package/src/Sink.reduce-collect-head-last.test.ts +107 -0
  569. package/src/Sink.ts +1 -1044
  570. package/src/Subject/Subject.ts +441 -0
  571. package/src/Subject/index.ts +1 -0
  572. package/src/Subject.test.ts +47 -0
  573. package/src/Subject.ts +1 -330
  574. package/src/Versioned/Versioned.ts +597 -0
  575. package/src/Versioned/index.ts +1 -0
  576. package/src/Versioned.filterMap.test.ts +91 -0
  577. package/src/Versioned.test.ts +23 -0
  578. package/src/Versioned.ts +1 -357
  579. package/src/index.ts +7 -130
  580. package/AsyncData/package.json +0 -6
  581. package/Emitter/package.json +0 -6
  582. package/Form/package.json +0 -6
  583. package/FormEntry/package.json +0 -6
  584. package/Fx/package.json +0 -6
  585. package/Idle/package.json +0 -6
  586. package/LICENSE +0 -21
  587. package/Match/package.json +0 -6
  588. package/Pull/package.json +0 -6
  589. package/Push/package.json +0 -6
  590. package/RefArray/package.json +0 -6
  591. package/RefChunk/package.json +0 -6
  592. package/RefHashMap/package.json +0 -6
  593. package/RefHashSet/package.json +0 -6
  594. package/RefSubject/package.json +0 -6
  595. package/Sink/package.json +0 -6
  596. package/Stream/package.json +0 -6
  597. package/Subject/package.json +0 -6
  598. package/TypeId/package.json +0 -6
  599. package/Typeclass/package.json +0 -6
  600. package/Versioned/package.json +0 -6
  601. package/dist/cjs/AsyncData.js +0 -188
  602. package/dist/cjs/AsyncData.js.map +0 -1
  603. package/dist/cjs/Emitter.js +0 -44
  604. package/dist/cjs/Emitter.js.map +0 -1
  605. package/dist/cjs/Form.js +0 -178
  606. package/dist/cjs/Form.js.map +0 -1
  607. package/dist/cjs/FormEntry.js +0 -110
  608. package/dist/cjs/FormEntry.js.map +0 -1
  609. package/dist/cjs/Fx.js +0 -998
  610. package/dist/cjs/Fx.js.map +0 -1
  611. package/dist/cjs/Idle.js +0 -190
  612. package/dist/cjs/Idle.js.map +0 -1
  613. package/dist/cjs/Match.js +0 -191
  614. package/dist/cjs/Match.js.map +0 -1
  615. package/dist/cjs/Pull.js +0 -52
  616. package/dist/cjs/Pull.js.map +0 -1
  617. package/dist/cjs/Push.js +0 -168
  618. package/dist/cjs/Push.js.map +0 -1
  619. package/dist/cjs/RefArray.js +0 -253
  620. package/dist/cjs/RefArray.js.map +0 -1
  621. package/dist/cjs/RefChunk.js +0 -212
  622. package/dist/cjs/RefChunk.js.map +0 -1
  623. package/dist/cjs/RefHashMap.js +0 -198
  624. package/dist/cjs/RefHashMap.js.map +0 -1
  625. package/dist/cjs/RefHashSet.js +0 -99
  626. package/dist/cjs/RefHashSet.js.map +0 -1
  627. package/dist/cjs/RefSubject.js +0 -1115
  628. package/dist/cjs/RefSubject.js.map +0 -1
  629. package/dist/cjs/Sink.js +0 -662
  630. package/dist/cjs/Sink.js.map +0 -1
  631. package/dist/cjs/Stream.js +0 -87
  632. package/dist/cjs/Stream.js.map +0 -1
  633. package/dist/cjs/Subject.js +0 -205
  634. package/dist/cjs/Subject.js.map +0 -1
  635. package/dist/cjs/TypeId.js +0 -32
  636. package/dist/cjs/TypeId.js.map +0 -1
  637. package/dist/cjs/Typeclass.js +0 -380
  638. package/dist/cjs/Typeclass.js.map +0 -1
  639. package/dist/cjs/Versioned.js +0 -172
  640. package/dist/cjs/Versioned.js.map +0 -1
  641. package/dist/cjs/index.js +0 -89
  642. package/dist/cjs/index.js.map +0 -1
  643. package/dist/cjs/internal/DeferredRef.js +0 -67
  644. package/dist/cjs/internal/DeferredRef.js.map +0 -1
  645. package/dist/cjs/internal/UnionToTuple.js +0 -6
  646. package/dist/cjs/internal/UnionToTuple.js.map +0 -1
  647. package/dist/cjs/internal/bounds.js +0 -26
  648. package/dist/cjs/internal/bounds.js.map +0 -1
  649. package/dist/cjs/internal/core.js +0 -1783
  650. package/dist/cjs/internal/core.js.map +0 -1
  651. package/dist/cjs/internal/diff.js +0 -122
  652. package/dist/cjs/internal/diff.js.map +0 -1
  653. package/dist/cjs/internal/effect-loop-operator.js +0 -288
  654. package/dist/cjs/internal/effect-loop-operator.js.map +0 -1
  655. package/dist/cjs/internal/effect-operator.js +0 -156
  656. package/dist/cjs/internal/effect-operator.js.map +0 -1
  657. package/dist/cjs/internal/effect-producer.js +0 -74
  658. package/dist/cjs/internal/effect-producer.js.map +0 -1
  659. package/dist/cjs/internal/helpers.js +0 -317
  660. package/dist/cjs/internal/helpers.js.map +0 -1
  661. package/dist/cjs/internal/keyed.js +0 -168
  662. package/dist/cjs/internal/keyed.js.map +0 -1
  663. package/dist/cjs/internal/loop-operator.js +0 -213
  664. package/dist/cjs/internal/loop-operator.js.map +0 -1
  665. package/dist/cjs/internal/operator.js +0 -79
  666. package/dist/cjs/internal/operator.js.map +0 -1
  667. package/dist/cjs/internal/protos.js +0 -48
  668. package/dist/cjs/internal/protos.js.map +0 -1
  669. package/dist/cjs/internal/provide.js +0 -100
  670. package/dist/cjs/internal/provide.js.map +0 -1
  671. package/dist/cjs/internal/requestIdleCallback.js +0 -22
  672. package/dist/cjs/internal/requestIdleCallback.js.map +0 -1
  673. package/dist/cjs/internal/share.js +0 -74
  674. package/dist/cjs/internal/share.js.map +0 -1
  675. package/dist/cjs/internal/strategies.js +0 -34
  676. package/dist/cjs/internal/strategies.js.map +0 -1
  677. package/dist/cjs/internal/sync-operator.js +0 -120
  678. package/dist/cjs/internal/sync-operator.js.map +0 -1
  679. package/dist/cjs/internal/sync-producer.js +0 -118
  680. package/dist/cjs/internal/sync-producer.js.map +0 -1
  681. package/dist/cjs/internal/withKey.js +0 -63
  682. package/dist/cjs/internal/withKey.js.map +0 -1
  683. package/dist/dts/AsyncData.d.ts +0 -179
  684. package/dist/dts/AsyncData.d.ts.map +0 -1
  685. package/dist/dts/Emitter.d.ts +0 -24
  686. package/dist/dts/Emitter.d.ts.map +0 -1
  687. package/dist/dts/Form.d.ts +0 -145
  688. package/dist/dts/Form.d.ts.map +0 -1
  689. package/dist/dts/FormEntry.d.ts +0 -65
  690. package/dist/dts/FormEntry.d.ts.map +0 -1
  691. package/dist/dts/Fx.d.ts +0 -1678
  692. package/dist/dts/Fx.d.ts.map +0 -1
  693. package/dist/dts/Idle.d.ts +0 -84
  694. package/dist/dts/Idle.d.ts.map +0 -1
  695. package/dist/dts/Match.d.ts +0 -60
  696. package/dist/dts/Match.d.ts.map +0 -1
  697. package/dist/dts/Pull.d.ts +0 -37
  698. package/dist/dts/Pull.d.ts.map +0 -1
  699. package/dist/dts/Push.d.ts +0 -176
  700. package/dist/dts/Push.d.ts.map +0 -1
  701. package/dist/dts/RefArray.d.ts +0 -278
  702. package/dist/dts/RefArray.d.ts.map +0 -1
  703. package/dist/dts/RefChunk.d.ts +0 -230
  704. package/dist/dts/RefChunk.d.ts.map +0 -1
  705. package/dist/dts/RefHashMap.d.ts +0 -189
  706. package/dist/dts/RefHashMap.d.ts.map +0 -1
  707. package/dist/dts/RefHashSet.d.ts +0 -100
  708. package/dist/dts/RefHashSet.d.ts.map +0 -1
  709. package/dist/dts/RefSubject.d.ts +0 -601
  710. package/dist/dts/RefSubject.d.ts.map +0 -1
  711. package/dist/dts/Sink.d.ts +0 -252
  712. package/dist/dts/Sink.d.ts.map +0 -1
  713. package/dist/dts/Stream.d.ts +0 -66
  714. package/dist/dts/Stream.d.ts.map +0 -1
  715. package/dist/dts/Subject.d.ts +0 -61
  716. package/dist/dts/Subject.d.ts.map +0 -1
  717. package/dist/dts/TypeId.d.ts +0 -51
  718. package/dist/dts/TypeId.d.ts.map +0 -1
  719. package/dist/dts/Typeclass.d.ts +0 -284
  720. package/dist/dts/Typeclass.d.ts.map +0 -1
  721. package/dist/dts/Versioned.d.ts +0 -117
  722. package/dist/dts/Versioned.d.ts.map +0 -1
  723. package/dist/dts/index.d.ts +0 -111
  724. package/dist/dts/index.d.ts.map +0 -1
  725. package/dist/dts/internal/DeferredRef.d.ts +0 -22
  726. package/dist/dts/internal/DeferredRef.d.ts.map +0 -1
  727. package/dist/dts/internal/UnionToTuple.d.ts.map +0 -1
  728. package/dist/dts/internal/bounds.d.ts +0 -9
  729. package/dist/dts/internal/bounds.d.ts.map +0 -1
  730. package/dist/dts/internal/core.d.ts +0 -237
  731. package/dist/dts/internal/core.d.ts.map +0 -1
  732. package/dist/dts/internal/diff.d.ts +0 -42
  733. package/dist/dts/internal/diff.d.ts.map +0 -1
  734. package/dist/dts/internal/effect-loop-operator.d.ts +0 -34
  735. package/dist/dts/internal/effect-loop-operator.d.ts.map +0 -1
  736. package/dist/dts/internal/effect-operator.d.ts +0 -40
  737. package/dist/dts/internal/effect-operator.d.ts.map +0 -1
  738. package/dist/dts/internal/effect-producer.d.ts +0 -25
  739. package/dist/dts/internal/effect-producer.d.ts.map +0 -1
  740. package/dist/dts/internal/helpers.d.ts +0 -60
  741. package/dist/dts/internal/helpers.d.ts.map +0 -1
  742. package/dist/dts/internal/keyed.d.ts +0 -4
  743. package/dist/dts/internal/keyed.d.ts.map +0 -1
  744. package/dist/dts/internal/loop-operator.d.ts +0 -40
  745. package/dist/dts/internal/loop-operator.d.ts.map +0 -1
  746. package/dist/dts/internal/operator.d.ts +0 -16
  747. package/dist/dts/internal/operator.d.ts.map +0 -1
  748. package/dist/dts/internal/protos.d.ts +0 -23
  749. package/dist/dts/internal/protos.d.ts.map +0 -1
  750. package/dist/dts/internal/provide.d.ts +0 -46
  751. package/dist/dts/internal/provide.d.ts.map +0 -1
  752. package/dist/dts/internal/requestIdleCallback.d.ts +0 -3
  753. package/dist/dts/internal/requestIdleCallback.d.ts.map +0 -1
  754. package/dist/dts/internal/share.d.ts +0 -33
  755. package/dist/dts/internal/share.d.ts.map +0 -1
  756. package/dist/dts/internal/strategies.d.ts +0 -9
  757. package/dist/dts/internal/strategies.d.ts.map +0 -1
  758. package/dist/dts/internal/sync-operator.d.ts +0 -32
  759. package/dist/dts/internal/sync-operator.d.ts.map +0 -1
  760. package/dist/dts/internal/sync-producer.d.ts +0 -36
  761. package/dist/dts/internal/sync-producer.d.ts.map +0 -1
  762. package/dist/dts/internal/withKey.d.ts +0 -4
  763. package/dist/dts/internal/withKey.d.ts.map +0 -1
  764. package/dist/esm/AsyncData.js +0 -156
  765. package/dist/esm/AsyncData.js.map +0 -1
  766. package/dist/esm/Emitter.js +0 -33
  767. package/dist/esm/Emitter.js.map +0 -1
  768. package/dist/esm/Form.js +0 -163
  769. package/dist/esm/Form.js.map +0 -1
  770. package/dist/esm/FormEntry.js +0 -100
  771. package/dist/esm/FormEntry.js.map +0 -1
  772. package/dist/esm/Fx.js +0 -984
  773. package/dist/esm/Fx.js.map +0 -1
  774. package/dist/esm/Idle.js +0 -178
  775. package/dist/esm/Idle.js.map +0 -1
  776. package/dist/esm/Match.js +0 -185
  777. package/dist/esm/Match.js.map +0 -1
  778. package/dist/esm/Pull.js +0 -41
  779. package/dist/esm/Pull.js.map +0 -1
  780. package/dist/esm/Push.js +0 -159
  781. package/dist/esm/Push.js.map +0 -1
  782. package/dist/esm/RefArray.js +0 -234
  783. package/dist/esm/RefArray.js.map +0 -1
  784. package/dist/esm/RefChunk.js +0 -196
  785. package/dist/esm/RefChunk.js.map +0 -1
  786. package/dist/esm/RefHashMap.js +0 -176
  787. package/dist/esm/RefHashMap.js.map +0 -1
  788. package/dist/esm/RefHashSet.js +0 -86
  789. package/dist/esm/RefHashSet.js.map +0 -1
  790. package/dist/esm/RefSubject.js +0 -1076
  791. package/dist/esm/RefSubject.js.map +0 -1
  792. package/dist/esm/Sink.js +0 -673
  793. package/dist/esm/Sink.js.map +0 -1
  794. package/dist/esm/Stream.js +0 -76
  795. package/dist/esm/Stream.js.map +0 -1
  796. package/dist/esm/Subject.js +0 -198
  797. package/dist/esm/Subject.js.map +0 -1
  798. package/dist/esm/TypeId.js +0 -26
  799. package/dist/esm/TypeId.js.map +0 -1
  800. package/dist/esm/Typeclass.js +0 -375
  801. package/dist/esm/Typeclass.js.map +0 -1
  802. package/dist/esm/Versioned.js +0 -149
  803. package/dist/esm/Versioned.js.map +0 -1
  804. package/dist/esm/index.js +0 -111
  805. package/dist/esm/index.js.map +0 -1
  806. package/dist/esm/internal/DeferredRef.js +0 -57
  807. package/dist/esm/internal/DeferredRef.js.map +0 -1
  808. package/dist/esm/internal/UnionToTuple.js +0 -2
  809. package/dist/esm/internal/UnionToTuple.js.map +0 -1
  810. package/dist/esm/internal/bounds.js +0 -13
  811. package/dist/esm/internal/bounds.js.map +0 -1
  812. package/dist/esm/internal/core.js +0 -1647
  813. package/dist/esm/internal/core.js.map +0 -1
  814. package/dist/esm/internal/diff.js +0 -92
  815. package/dist/esm/internal/diff.js.map +0 -1
  816. package/dist/esm/internal/effect-loop-operator.js +0 -269
  817. package/dist/esm/internal/effect-loop-operator.js.map +0 -1
  818. package/dist/esm/internal/effect-operator.js +0 -134
  819. package/dist/esm/internal/effect-operator.js.map +0 -1
  820. package/dist/esm/internal/effect-producer.js +0 -47
  821. package/dist/esm/internal/effect-producer.js.map +0 -1
  822. package/dist/esm/internal/helpers.js +0 -299
  823. package/dist/esm/internal/helpers.js.map +0 -1
  824. package/dist/esm/internal/keyed.js +0 -153
  825. package/dist/esm/internal/keyed.js.map +0 -1
  826. package/dist/esm/internal/loop-operator.js +0 -186
  827. package/dist/esm/internal/loop-operator.js.map +0 -1
  828. package/dist/esm/internal/operator.js +0 -68
  829. package/dist/esm/internal/operator.js.map +0 -1
  830. package/dist/esm/internal/protos.js +0 -39
  831. package/dist/esm/internal/protos.js.map +0 -1
  832. package/dist/esm/internal/provide.js +0 -72
  833. package/dist/esm/internal/provide.js.map +0 -1
  834. package/dist/esm/internal/requestIdleCallback.js +0 -16
  835. package/dist/esm/internal/requestIdleCallback.js.map +0 -1
  836. package/dist/esm/internal/share.js +0 -62
  837. package/dist/esm/internal/share.js.map +0 -1
  838. package/dist/esm/internal/strategies.js +0 -8
  839. package/dist/esm/internal/strategies.js.map +0 -1
  840. package/dist/esm/internal/sync-operator.js +0 -95
  841. package/dist/esm/internal/sync-operator.js.map +0 -1
  842. package/dist/esm/internal/sync-producer.js +0 -90
  843. package/dist/esm/internal/sync-producer.js.map +0 -1
  844. package/dist/esm/internal/withKey.js +0 -56
  845. package/dist/esm/internal/withKey.js.map +0 -1
  846. package/dist/esm/package.json +0 -4
  847. package/src/AsyncData.ts +0 -453
  848. package/src/Emitter.ts +0 -59
  849. package/src/Form.ts +0 -489
  850. package/src/FormEntry.ts +0 -214
  851. package/src/Idle.ts +0 -294
  852. package/src/Match.ts +0 -314
  853. package/src/Pull.ts +0 -95
  854. package/src/RefArray.ts +0 -514
  855. package/src/RefChunk.ts +0 -407
  856. package/src/RefHashMap.ts +0 -335
  857. package/src/RefHashSet.ts +0 -179
  858. package/src/Stream.ts +0 -140
  859. package/src/TypeId.ts +0 -59
  860. package/src/Typeclass.ts +0 -459
  861. package/src/internal/DeferredRef.ts +0 -72
  862. package/src/internal/UnionToTuple.ts +0 -11
  863. package/src/internal/bounds.ts +0 -21
  864. package/src/internal/core.ts +0 -3091
  865. package/src/internal/diff.ts +0 -171
  866. package/src/internal/effect-loop-operator.ts +0 -466
  867. package/src/internal/effect-operator.ts +0 -317
  868. package/src/internal/effect-producer.ts +0 -125
  869. package/src/internal/helpers.ts +0 -538
  870. package/src/internal/keyed.ts +0 -235
  871. package/src/internal/loop-operator.ts +0 -266
  872. package/src/internal/operator.ts +0 -87
  873. package/src/internal/protos.ts +0 -57
  874. package/src/internal/provide.ts +0 -151
  875. package/src/internal/requestIdleCallback.ts +0 -19
  876. package/src/internal/share.ts +0 -97
  877. package/src/internal/strategies.ts +0 -15
  878. package/src/internal/sync-operator.ts +0 -166
  879. package/src/internal/sync-producer.ts +0 -148
  880. package/src/internal/withKey.ts +0 -82
  881. /package/dist/{dts → Fx}/internal/UnionToTuple.d.ts +0 -0
@@ -0,0 +1,13 @@
1
+ import { dual, flow } from "effect/Function";
2
+ import { fromEffect } from "../constructors/fromEffect.js";
3
+ import { flatMapConcurrently } from "./flatMapConcurrently.js";
4
+ /**
5
+ * Maps each element of an Fx to an Effect, running them concurrently with a limit.
6
+ *
7
+ * @param f - A function that maps an element `A` to an `Effect<B>`.
8
+ * @param concurrency - The maximum number of concurrent effects.
9
+ * @returns An `Fx` that emits the results of the effects.
10
+ * @since 1.0.0
11
+ * @category combinators
12
+ */
13
+ export const flatMapConcurrentlyEffect = dual(3, (self, f, concurrency) => flatMapConcurrently(self, flow(f, fromEffect), concurrency));
@@ -0,0 +1,24 @@
1
+ import type * as Effect from "effect/Effect";
2
+ import type * as Scope from "effect/Scope";
3
+ import type { Fx } from "../Fx.js";
4
+ /**
5
+ * Type definition for flatMapEffect functions to support variable arguments.
6
+ * @since 1.0.0
7
+ * @category types
8
+ */
9
+ export type FlatMapEffectLike<Args extends ReadonlyArray<any> = []> = {
10
+ <A, B, E2, R2>(f: (a: A) => Effect.Effect<B, E2, R2>, ...args: Args): <E, R>(self: Fx<A, E, R>) => Fx<B, E | E2, R | R2 | Scope.Scope>;
11
+ <A, E, R, B, E2, R2>(self: Fx<A, E, R>, f: (a: A) => Effect.Effect<B, E2, R2>, ...args: Args): Fx<B, E | E2, R | R2 | Scope.Scope>;
12
+ };
13
+ /**
14
+ * Maps each element of an Fx to an Effect, and merges the results.
15
+ *
16
+ * The effects are run concurrently.
17
+ *
18
+ * @param f - A function that maps an element `A` to an `Effect<B>`.
19
+ * @returns An `Fx` that emits the results of the effects.
20
+ * @since 1.0.0
21
+ * @category combinators
22
+ */
23
+ export declare const flatMapEffect: FlatMapEffectLike;
24
+ //# sourceMappingURL=flatMapEffect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"flatMapEffect.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/flatMapEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,MAAM,eAAe,CAAC;AAE7C,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAC;AAE3C,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAGnC;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,CAAC,IAAI,SAAS,aAAa,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI;IACpE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EACX,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,EAAE,EAAE,EAAE,CAAC,EACrC,GAAG,IAAI,EAAE,IAAI,GACZ,CAAC,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC;IAEpE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EACjB,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACjB,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,EAAE,EAAE,EAAE,CAAC,EACrC,GAAG,IAAI,EAAE,IAAI,GACZ,EAAE,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC;CACxC,CAAC;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,aAAa,EAAE,iBAM3B,CAAC"}
@@ -0,0 +1,14 @@
1
+ import { dual, flow } from "effect/Function";
2
+ import { fromEffect } from "../constructors/fromEffect.js";
3
+ import { flatMap } from "./flatMap.js";
4
+ /**
5
+ * Maps each element of an Fx to an Effect, and merges the results.
6
+ *
7
+ * The effects are run concurrently.
8
+ *
9
+ * @param f - A function that maps an element `A` to an `Effect<B>`.
10
+ * @returns An `Fx` that emits the results of the effects.
11
+ * @since 1.0.0
12
+ * @category combinators
13
+ */
14
+ export const flatMapEffect = dual(2, (self, f) => flatMap(self, flow(f, fromEffect)));
@@ -0,0 +1,11 @@
1
+ import type { Fx } from "../Fx.js";
2
+ /**
3
+ * Flips the error and success channels of an Fx.
4
+ *
5
+ * @param fx - The `Fx` stream.
6
+ * @returns An `Fx` where errors are successes and successes are errors.
7
+ * @since 1.0.0
8
+ * @category combinators
9
+ */
10
+ export declare const flip: <A, E, R>(fx: Fx<A, E, R>) => Fx<E, A, R>;
11
+ //# sourceMappingURL=flip.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"flip.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/flip.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAEnC;;;;;;;GAOG;AACH,eAAO,MAAM,IAAI,GAAI,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,KAAG,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CACJ,CAAC"}
@@ -0,0 +1,11 @@
1
+ import * as sinkCore from "../../Sink/combinators.js";
2
+ import { make } from "../constructors/make.js";
3
+ /**
4
+ * Flips the error and success channels of an Fx.
5
+ *
6
+ * @param fx - The `Fx` stream.
7
+ * @returns An `Fx` where errors are successes and successes are errors.
8
+ * @since 1.0.0
9
+ * @category combinators
10
+ */
11
+ export const flip = (fx) => make((sink) => fx.run(sinkCore.flip(sink)));
@@ -0,0 +1,20 @@
1
+ import * as Effect from "effect/Effect";
2
+ import type { Fx } from "../Fx.js";
3
+ /** Extract error type from Yieldable (Effect v4) */
4
+ type _YE<Y> = Y extends Effect.Yieldable<any, any, infer E, any> ? E : never;
5
+ /** Extract services type from Yieldable (Effect v4) */
6
+ type _YS<Y> = Y extends Effect.Yieldable<any, any, any, infer R> ? R : never;
7
+ /**
8
+ * Creates an Fx using a generator function (Effect.gen style).
9
+ *
10
+ * This allows writing Fx code in a synchronous-looking style, using `yield*` to composition.
11
+ * Note: The generator yields Effects, and the result is an Fx.
12
+ *
13
+ * @param f - The generator function.
14
+ * @returns An `Fx` representing the result of the generator.
15
+ * @since 1.0.0
16
+ * @category combinators
17
+ */
18
+ export declare const gen: <Yield extends Effect.Yieldable<any, any, any, any>, Return extends Fx.Any>(f: () => Generator<Yield, Return, any>) => Fx<Fx.Success<Return>, Fx.Error<Return> | _YE<Yield>, Fx.Services<Return> | _YS<Yield>>;
19
+ export {};
20
+ //# sourceMappingURL=gen.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gen.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/gen.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAGnC,oDAAoD;AACpD,KAAK,GAAG,CAAC,CAAC,IAAI,CAAC,SAAS,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,MAAM,CAAC,EAAE,GAAG,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;AAC7E,uDAAuD;AACvD,KAAK,GAAG,CAAC,CAAC,IAAI,CAAC,SAAS,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;AAE7E;;;;;;;;;;GAUG;AACH,eAAO,MAAM,GAAG,GAAI,KAAK,SAAS,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,MAAM,SAAS,EAAE,CAAC,GAAG,EAC3F,GAAG,MAAM,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,CAAC,KACrC,EAAE,CAAC,EAAE,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,CAC3D,CAAC"}
@@ -0,0 +1,14 @@
1
+ import * as Effect from "effect/Effect";
2
+ import { unwrap } from "./unwrap.js";
3
+ /**
4
+ * Creates an Fx using a generator function (Effect.gen style).
5
+ *
6
+ * This allows writing Fx code in a synchronous-looking style, using `yield*` to composition.
7
+ * Note: The generator yields Effects, and the result is an Fx.
8
+ *
9
+ * @param f - The generator function.
10
+ * @returns An `Fx` representing the result of the generator.
11
+ * @since 1.0.0
12
+ * @category combinators
13
+ */
14
+ export const gen = (f) => unwrap(Effect.gen(f));
@@ -0,0 +1,20 @@
1
+ import * as Effect from "effect/Effect";
2
+ import type * as Scope from "effect/Scope";
3
+ import type { Fx } from "../Fx.js";
4
+ /** Extract error type from Yieldable (Effect v4) */
5
+ type _YE<Y> = Y extends Effect.Yieldable<any, any, infer E, any> ? E : never;
6
+ /** Extract services type from Yieldable (Effect v4) */
7
+ type _YS<Y> = Y extends Effect.Yieldable<any, any, any, infer R> ? R : never;
8
+ /**
9
+ * Creates a scoped Fx using a generator function.
10
+ *
11
+ * Similar to `gen`, but also handles resource management via Scope.
12
+ *
13
+ * @param f - The generator function.
14
+ * @returns An `Fx` representing the result of the generator.
15
+ * @since 1.0.0
16
+ * @category combinators
17
+ */
18
+ export declare const genScoped: <Yield extends Effect.Yieldable<any, any, any, any>, A, E, R>(f: () => Generator<Yield, Fx<A, E, R>, any>) => Fx<A, E | _YE<Yield>, Exclude<R | _YS<Yield>, Scope.Scope>>;
19
+ export {};
20
+ //# sourceMappingURL=genScoped.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"genScoped.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/genScoped.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAC;AAC3C,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAGnC,oDAAoD;AACpD,KAAK,GAAG,CAAC,CAAC,IAAI,CAAC,SAAS,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,MAAM,CAAC,EAAE,GAAG,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;AAC7E,uDAAuD;AACvD,KAAK,GAAG,CAAC,CAAC,IAAI,CAAC,SAAS,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;AAE7E;;;;;;;;;GASG;AACH,eAAO,MAAM,SAAS,GAAI,KAAK,SAAS,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EACnF,GAAG,MAAM,SAAS,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,KAC1C,EAAE,CAAC,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC,CAAC,GAAG,GAAG,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,KAAK,CAAC,CACzB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import * as Effect from "effect/Effect";
2
+ import { unwrapScoped } from "./unwrapScoped.js";
3
+ /**
4
+ * Creates a scoped Fx using a generator function.
5
+ *
6
+ * Similar to `gen`, but also handles resource management via Scope.
7
+ *
8
+ * @param f - The generator function.
9
+ * @returns An `Fx` representing the result of the generator.
10
+ * @since 1.0.0
11
+ * @category combinators
12
+ */
13
+ export const genScoped = (f) => unwrapScoped(Effect.gen(f));
@@ -0,0 +1,62 @@
1
+ export * from "./catch.js";
2
+ export * from "./changesWithEffect.js";
3
+ export * from "./causes.js";
4
+ export * from "./compact.js";
5
+ export * from "./continueWith.js";
6
+ export * from "./dropUntil.js";
7
+ export * from "./additive.js";
8
+ export * from "./ensuring.js";
9
+ export * from "./exhaustLatestMap.js";
10
+ export * from "./exhaustLatestMapEffect.js";
11
+ export * from "./exhaustMap.js";
12
+ export * from "./exhaustMapEffect.js";
13
+ export * from "./exit.js";
14
+ export * from "./filter.js";
15
+ export * from "./filterEffect.js";
16
+ export * from "./filterMap.js";
17
+ export * from "./filterMapEffect.js";
18
+ export * from "./filterMapLoop.js";
19
+ export * from "./filterMapLoopCause.js";
20
+ export * from "./filterMapLoopCauseEffect.js";
21
+ export * from "./filterMapLoopEffect.js";
22
+ export * from "./flatMap.js";
23
+ export * from "./flatMapConcurrently.js";
24
+ export * from "./flatMapConcurrentlyEffect.js";
25
+ export * from "./flatMapEffect.js";
26
+ export * from "./flip.js";
27
+ export * from "./gen.js";
28
+ export * from "./genScoped.js";
29
+ export * from "./keyed.js";
30
+ export * from "./loop.js";
31
+ export * from "./loopCause.js";
32
+ export * from "./loopCauseEffect.js";
33
+ export * from "./loopEffect.js";
34
+ export * from "./map.js";
35
+ export * from "./mapBoth.js";
36
+ export * from "./mapEffect.js";
37
+ export * from "./mapError.js";
38
+ export * from "./mergeAll.js";
39
+ export * from "./mergeOrdered.js";
40
+ export * from "./onError.js";
41
+ export * from "./onExit.js";
42
+ export * from "./onInterrupt.js";
43
+ export * from "./provide.js";
44
+ export * from "./result.js";
45
+ export * from "./scan.js";
46
+ export * from "./skip.js";
47
+ export * from "./skipRepeats.js";
48
+ export * from "./skipWhile.js";
49
+ export * from "./skipRepeatsWith.js";
50
+ export * from "./slice.js";
51
+ export * from "./switchMap.js";
52
+ export * from "./switchMapEffect.js";
53
+ export * from "./take.js";
54
+ export * from "./takeUntil.js";
55
+ export * from "./takeWhile.js";
56
+ export * from "./tapEffect.js";
57
+ export * from "./tuple.js";
58
+ export * from "./unwrap.js";
59
+ export * from "./unwrapScoped.js";
60
+ export * from "./when.js";
61
+ export * from "./zip.js";
62
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,wBAAwB,CAAC;AACvC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,uBAAuB,CAAC;AACtC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,cAAc,yBAAyB,CAAC;AACxC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC;AACzC,cAAc,cAAc,CAAC;AAC7B,cAAc,0BAA0B,CAAC;AACzC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAmB,CAAC;AAClC,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC"}
@@ -0,0 +1,61 @@
1
+ export * from "./catch.js";
2
+ export * from "./changesWithEffect.js";
3
+ export * from "./causes.js";
4
+ export * from "./compact.js";
5
+ export * from "./continueWith.js";
6
+ export * from "./dropUntil.js";
7
+ export * from "./additive.js";
8
+ export * from "./ensuring.js";
9
+ export * from "./exhaustLatestMap.js";
10
+ export * from "./exhaustLatestMapEffect.js";
11
+ export * from "./exhaustMap.js";
12
+ export * from "./exhaustMapEffect.js";
13
+ export * from "./exit.js";
14
+ export * from "./filter.js";
15
+ export * from "./filterEffect.js";
16
+ export * from "./filterMap.js";
17
+ export * from "./filterMapEffect.js";
18
+ export * from "./filterMapLoop.js";
19
+ export * from "./filterMapLoopCause.js";
20
+ export * from "./filterMapLoopCauseEffect.js";
21
+ export * from "./filterMapLoopEffect.js";
22
+ export * from "./flatMap.js";
23
+ export * from "./flatMapConcurrently.js";
24
+ export * from "./flatMapConcurrentlyEffect.js";
25
+ export * from "./flatMapEffect.js";
26
+ export * from "./flip.js";
27
+ export * from "./gen.js";
28
+ export * from "./genScoped.js";
29
+ export * from "./keyed.js";
30
+ export * from "./loop.js";
31
+ export * from "./loopCause.js";
32
+ export * from "./loopCauseEffect.js";
33
+ export * from "./loopEffect.js";
34
+ export * from "./map.js";
35
+ export * from "./mapBoth.js";
36
+ export * from "./mapEffect.js";
37
+ export * from "./mapError.js";
38
+ export * from "./mergeAll.js";
39
+ export * from "./mergeOrdered.js";
40
+ export * from "./onError.js";
41
+ export * from "./onExit.js";
42
+ export * from "./onInterrupt.js";
43
+ export * from "./provide.js";
44
+ export * from "./result.js";
45
+ export * from "./scan.js";
46
+ export * from "./skip.js";
47
+ export * from "./skipRepeats.js";
48
+ export * from "./skipWhile.js";
49
+ export * from "./skipRepeatsWith.js";
50
+ export * from "./slice.js";
51
+ export * from "./switchMap.js";
52
+ export * from "./switchMapEffect.js";
53
+ export * from "./take.js";
54
+ export * from "./takeUntil.js";
55
+ export * from "./takeWhile.js";
56
+ export * from "./tapEffect.js";
57
+ export * from "./tuple.js";
58
+ export * from "./unwrap.js";
59
+ export * from "./unwrapScoped.js";
60
+ export * from "./when.js";
61
+ export * from "./zip.js";
@@ -0,0 +1,44 @@
1
+ import * as Duration from "effect/Duration";
2
+ import * as Scope from "effect/Scope";
3
+ import * as RefSubject from "../../RefSubject/RefSubject.js";
4
+ import type { Fx } from "../Fx.js";
5
+ /**
6
+ * Configuration options for the `keyed` combinator.
7
+ * @since 1.0.0
8
+ * @category models
9
+ */
10
+ export interface KeyedOptions<A, B, C, E2, R2> {
11
+ /**
12
+ * Function to extract a unique key from an element.
13
+ */
14
+ readonly getKey: (a: A) => B;
15
+ /**
16
+ * Function to transform a value into an Fx, receiving a RefSubject of the value.
17
+ * This allows the transformation to react to updates of the same item (same key).
18
+ */
19
+ readonly onValue: (ref: RefSubject.RefSubject<A>, key: B) => Fx<C, E2, R2 | Scope.Scope>;
20
+ /**
21
+ * Optional debounce duration for emission.
22
+ */
23
+ readonly debounce?: Duration.Input;
24
+ }
25
+ /**
26
+ * Efficiently transforms a list of values into a list of Fx streams, using keys to track identity.
27
+ *
28
+ * This is crucial for performance when rendering lists or managing collections of stateful entities.
29
+ * When the input list changes:
30
+ * - New keys cause `onValue` to be called.
31
+ * - Existing keys have their `RefSubject` updated with the new value.
32
+ * - Removed keys have their corresponding Fx and scope cleaned up.
33
+ *
34
+ * @param fx - An `Fx` emitting an array of values.
35
+ * @param options - Configuration options.
36
+ * @returns An `Fx` emitting an array of results.
37
+ * @since 1.0.0
38
+ * @category combinators
39
+ */
40
+ export declare const keyed: {
41
+ <A, B extends PropertyKey, C, E2, R2>(options: KeyedOptions<A, B, C, E2, R2>): <E, R>(fx: Fx<ReadonlyArray<A>, E, R>) => Fx<ReadonlyArray<C>, E | E2, R | R2 | Scope.Scope>;
42
+ <A, E, R, B extends PropertyKey, C, E2, R2>(fx: Fx<ReadonlyArray<A>, E, R>, options: KeyedOptions<A, B, C, E2, R2>): Fx<ReadonlyArray<C>, E | E2, R | R2 | Scope.Scope>;
43
+ };
44
+ //# sourceMappingURL=keyed.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"keyed.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/keyed.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,QAAQ,MAAM,iBAAiB,CAAC;AAQ5C,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AAItC,OAAO,KAAK,UAAU,MAAM,gCAAgC,CAAC;AAE7D,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAMnC;;;;GAIG;AACH,MAAM,WAAW,YAAY,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE;IAC3C;;OAEG;IACH,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC;IAC7B;;;OAGG;IACH,QAAQ,CAAC,OAAO,EAAE,CAAC,GAAG,EAAE,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,EAAE,EAAE,EAAE,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC;IACzF;;OAEG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,QAAQ,CAAC,KAAK,CAAC;CACpC;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,KAAK,EAAE;IAClB,CAAC,CAAC,EAAE,CAAC,SAAS,WAAW,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EAClC,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,CAAC,GACrC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC;IAChG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,SAAS,WAAW,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,EACxC,EAAE,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAC9B,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,CAAC,GACrC,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC;CAetD,CAAC"}
@@ -0,0 +1,199 @@
1
+ import * as Clock from "effect/Clock";
2
+ import * as Duration from "effect/Duration";
3
+ import * as Effect from "effect/Effect";
4
+ import * as Exit from "effect/Exit";
5
+ import * as Fiber from "effect/Fiber";
6
+ import { dual, identity } from "effect/Function";
7
+ import * as Option from "effect/Option";
8
+ import { pipeArguments } from "effect/Pipeable";
9
+ import { MaxOpsBeforeYield } from "effect/Scheduler";
10
+ import * as Scope from "effect/Scope";
11
+ import * as ServiceMap from "effect/ServiceMap";
12
+ import * as SynchronizedRef from "effect/SynchronizedRef";
13
+ import * as RefSubject from "../../RefSubject/RefSubject.js";
14
+ import * as Sink from "../../Sink/Sink.js";
15
+ import { diff, getKeyMap } from "../internal/diff.js";
16
+ import { withScopedFork } from "../internal/scope.js";
17
+ import { FxTypeId } from "../TypeId.js";
18
+ /**
19
+ * Efficiently transforms a list of values into a list of Fx streams, using keys to track identity.
20
+ *
21
+ * This is crucial for performance when rendering lists or managing collections of stateful entities.
22
+ * When the input list changes:
23
+ * - New keys cause `onValue` to be called.
24
+ * - Existing keys have their `RefSubject` updated with the new value.
25
+ * - Removed keys have their corresponding Fx and scope cleaned up.
26
+ *
27
+ * @param fx - An `Fx` emitting an array of values.
28
+ * @param options - Configuration options.
29
+ * @returns An `Fx` emitting an array of results.
30
+ * @since 1.0.0
31
+ * @category combinators
32
+ */
33
+ export const keyed = dual(2, function keyed(fx, options) {
34
+ return new Keyed(fx, options);
35
+ });
36
+ const StateContext = ServiceMap.Service("@services/StateContext");
37
+ const VARIANCE = {
38
+ _A: identity,
39
+ _E: identity,
40
+ _R: identity,
41
+ };
42
+ class Keyed {
43
+ [FxTypeId] = VARIANCE;
44
+ fx;
45
+ options;
46
+ constructor(fx, options) {
47
+ this.fx = fx;
48
+ this.options = options;
49
+ }
50
+ run(sink) {
51
+ return Effect.withFiber((fiber) => runKeyed(this.fx, this.options, sink, fiber.id)).pipe(Effect.provideService(MaxOpsBeforeYield, Infinity));
52
+ }
53
+ pipe() {
54
+ return pipeArguments(this, arguments);
55
+ }
56
+ }
57
+ function emptyKeyedState() {
58
+ return {
59
+ entries: new Map(),
60
+ indices: new Map(),
61
+ previousValues: [],
62
+ };
63
+ }
64
+ function runKeyed(fx, options, sink, id) {
65
+ return withDebounceFork((debounceFork, parentScope) => {
66
+ const state = emptyKeyedState();
67
+ const emit = Effect.suspend(() => sink.onSuccess(getReadyIndices(state)));
68
+ const scheduleNextEmit = debounceFork(emit);
69
+ let first = true;
70
+ let previousKeyMap = new Map();
71
+ return fx.run(Sink.make(sink.onFailure, Effect.fn(function* (values) {
72
+ const previous = state.previousValues;
73
+ const keyMap = getKeyMap(values, options.getKey);
74
+ let changed = first;
75
+ first = false;
76
+ for (const patch of diff(previous, values, {
77
+ getKey: options.getKey,
78
+ previousKeyMap,
79
+ keyMap,
80
+ })) {
81
+ if (patch._tag === "Remove") {
82
+ changed = true;
83
+ yield* removeValue(state, patch, state.entries.get(patch.key));
84
+ }
85
+ else if (patch._tag === "Add") {
86
+ changed = true;
87
+ yield* addValue({
88
+ state,
89
+ values,
90
+ patch,
91
+ id,
92
+ parentScope,
93
+ keyedOptions: options,
94
+ sink,
95
+ scheduleNextEmit,
96
+ });
97
+ }
98
+ else {
99
+ yield* updateValue(state, values, patch);
100
+ }
101
+ }
102
+ state.previousValues = values;
103
+ previousKeyMap = keyMap;
104
+ if (changed) {
105
+ yield* scheduleNextEmit;
106
+ }
107
+ else {
108
+ yield* adjustTime();
109
+ }
110
+ })));
111
+ }, options.debounce || 1);
112
+ }
113
+ class KeyedEntry {
114
+ value;
115
+ index;
116
+ output;
117
+ ref;
118
+ interrupt;
119
+ constructor(value, index, output, ref, interrupt) {
120
+ this.value = value;
121
+ this.index = index;
122
+ this.output = output;
123
+ this.ref = ref;
124
+ this.interrupt = interrupt;
125
+ }
126
+ }
127
+ function getReadyIndices({ entries, indices, previousValues, }) {
128
+ const output = [];
129
+ for (let i = 0; i < previousValues.length; ++i) {
130
+ const key = indices.get(i);
131
+ if (key === undefined)
132
+ break;
133
+ const entry = entries.get(key);
134
+ if (Option.isSome(entry.output)) {
135
+ output.push(entry.output.value);
136
+ }
137
+ else {
138
+ break;
139
+ }
140
+ }
141
+ return output;
142
+ }
143
+ function* addValue(options) {
144
+ const { id, keyedOptions, parentScope, patch, scheduleNextEmit, sink, state, values } = options;
145
+ const { entries, indices } = state;
146
+ const value = values[patch.index];
147
+ const childScope = yield* Scope.fork(parentScope, "sequential");
148
+ const ref = yield* RefSubject.make(Effect.sync(() => entry.value)).pipe(Effect.provideService(Scope.Scope, childScope));
149
+ const entry = new KeyedEntry(value, patch.index, Option.none(), ref, Scope.close(childScope, Exit.interrupt(id)));
150
+ entries.set(patch.key, entry);
151
+ indices.set(patch.index, patch.key);
152
+ yield* Effect.forkIn(keyedOptions
153
+ .onValue(ref, patch.key)
154
+ .run(Sink.make((cause) => sink.onFailure(cause), (output) => {
155
+ entry.output = Option.some(output);
156
+ return scheduleNextEmit;
157
+ }))
158
+ .pipe(Effect.provideService(Scope.Scope, childScope)), parentScope);
159
+ }
160
+ function removeValue({ entries, indices }, patch, entry) {
161
+ entries.delete(patch.key);
162
+ indices.delete(patch.index);
163
+ return entry.interrupt;
164
+ }
165
+ function updateValue({ entries, indices }, values, patch) {
166
+ const key = patch.key;
167
+ const entry = entries.get(key);
168
+ if (patch._tag === "Moved") {
169
+ const currentKey = indices.get(patch.index);
170
+ if (currentKey === key) {
171
+ indices.delete(patch.index);
172
+ }
173
+ indices.set(patch.to, key);
174
+ entry.value = values[(entry.index = patch.to)];
175
+ }
176
+ else {
177
+ entry.value = values[(entry.index = patch.index)];
178
+ }
179
+ return RefSubject.set(entry.ref, entry.value);
180
+ }
181
+ function withDebounceFork(f, duration) {
182
+ return withScopedFork((fork, scope) => Effect.flatMap(SynchronizedRef.make(Option.none()), (ref) => Effect.flatMap(f((effect) => SynchronizedRef.updateEffect(ref, Option.match({
183
+ onNone: () => Effect.asSome(fork(Effect.delay(effect, duration))),
184
+ onSome: (fiber) => Fiber.interrupt(fiber).pipe(Effect.flatMap(() => fork(Effect.delay(effect, duration))), Effect.asSome),
185
+ })), scope), () => SynchronizedRef.updateEffect(ref, Option.match({
186
+ onNone: () => Effect.succeedNone,
187
+ onSome: (fiber) => Fiber.join(fiber).pipe(Effect.as(Option.none())),
188
+ })))), "sequential");
189
+ }
190
+ function* adjustTime() {
191
+ const services = yield* Effect.services();
192
+ const clock = ServiceMap.get(services, Clock.Clock);
193
+ if ("adjust" in clock) {
194
+ yield* clock.adjust(Duration.millis(1));
195
+ }
196
+ else {
197
+ yield* clock.sleep(Duration.millis(1));
198
+ }
199
+ }
@@ -0,0 +1,16 @@
1
+ import type { Fx } from "../Fx.js";
2
+ /**
3
+ * Loops over an Fx with an accumulator, producing a new value for each element
4
+ * and updating the accumulator.
5
+ *
6
+ * @param seed - The initial value of the accumulator.
7
+ * @param f - A function that takes the accumulator and an element, returning a tuple of the emitted value and the new accumulator.
8
+ * @returns An `Fx` that emits the transformed values.
9
+ * @since 1.0.0
10
+ * @category combinators
11
+ */
12
+ export declare const loop: {
13
+ <B, A, C>(seed: B, f: (acc: B, a: A) => readonly [C, B]): <E, R>(self: Fx<A, E, R>) => Fx<C, E, R>;
14
+ <A, E, R, B, C>(self: Fx<A, E, R>, seed: B, f: (acc: B, a: A) => readonly [C, B]): Fx<C, E, R>;
15
+ };
16
+ //# sourceMappingURL=loop.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"loop.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/loop.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAEnC;;;;;;;;;GASG;AACH,eAAO,MAAM,IAAI,EAAE;IACjB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EACN,IAAI,EAAE,CAAC,EACP,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,GACnC,CAAC,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IAE5C,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;CAKhG,CAAC"}
@@ -0,0 +1,14 @@
1
+ import { dual } from "effect/Function";
2
+ import * as sinkCore from "../../Sink/combinators.js";
3
+ import { make } from "../constructors/make.js";
4
+ /**
5
+ * Loops over an Fx with an accumulator, producing a new value for each element
6
+ * and updating the accumulator.
7
+ *
8
+ * @param seed - The initial value of the accumulator.
9
+ * @param f - A function that takes the accumulator and an element, returning a tuple of the emitted value and the new accumulator.
10
+ * @returns An `Fx` that emits the transformed values.
11
+ * @since 1.0.0
12
+ * @category combinators
13
+ */
14
+ export const loop = dual(3, (self, seed, f) => make((sink) => self.run(sinkCore.loop(sink, seed, f))));
@@ -0,0 +1,16 @@
1
+ import type * as Cause from "effect/Cause";
2
+ import type { Fx } from "../Fx.js";
3
+ /**
4
+ * Loops over the failure causes of an Fx with an accumulator.
5
+ *
6
+ * @param seed - The initial state.
7
+ * @param f - The loop function for causes.
8
+ * @returns An `Fx` with transformed errors.
9
+ * @since 1.0.0
10
+ * @category combinators
11
+ */
12
+ export declare const loopCause: {
13
+ <B, A, C>(seed: B, f: (acc: B, a: Cause.Cause<A>) => readonly [Cause.Cause<C>, B]): <E, R>(self: Fx<A, E, R>) => Fx<A, C, R>;
14
+ <A, E, R, B, C>(self: Fx<A, E, R>, seed: B, f: (acc: B, a: Cause.Cause<E>) => readonly [Cause.Cause<C>, B]): Fx<A, C, R>;
15
+ };
16
+ //# sourceMappingURL=loopCause.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"loopCause.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/loopCause.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAC;AAI3C,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAEnC;;;;;;;;GAQG;AACH,eAAO,MAAM,SAAS,EAAE;IACtB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EACN,IAAI,EAAE,CAAC,EACP,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAC7D,CAAC,CAAC,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IAE5C,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EACZ,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACjB,IAAI,EAAE,CAAC,EACP,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,SAAS,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAC7D,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;CAQhB,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { dual } from "effect/Function";
2
+ import * as sinkCore from "../../Sink/combinators.js";
3
+ import { make } from "../constructors/make.js";
4
+ /**
5
+ * Loops over the failure causes of an Fx with an accumulator.
6
+ *
7
+ * @param seed - The initial state.
8
+ * @param f - The loop function for causes.
9
+ * @returns An `Fx` with transformed errors.
10
+ * @since 1.0.0
11
+ * @category combinators
12
+ */
13
+ export const loopCause = dual(3, (self, seed, f) => make((sink) => self.run(sinkCore.loopCause(sink, seed, f))));
@@ -0,0 +1,17 @@
1
+ import type * as Cause from "effect/Cause";
2
+ import type * as Effect from "effect/Effect";
3
+ import type { Fx } from "../Fx.js";
4
+ /**
5
+ * Effectfully loops over the failure causes of an Fx with an accumulator.
6
+ *
7
+ * @param seed - The initial state.
8
+ * @param f - The effectful loop function for causes.
9
+ * @returns An `Fx` with transformed errors.
10
+ * @since 1.0.0
11
+ * @category combinators
12
+ */
13
+ export declare const loopCauseEffect: {
14
+ <B, A, E, R2, C>(seed: B, f: (acc: B, a: Cause.Cause<A>) => Effect.Effect<readonly [Cause.Cause<C>, B], R2>): <R>(self: Fx<A, E, R>) => Fx<A, C | E, R | R2>;
15
+ <A, E, R, B, R2, C>(self: Fx<A, E, R>, seed: B, f: (acc: B, a: Cause.Cause<E>) => Effect.Effect<readonly [Cause.Cause<C>, B], E, R2>): Fx<A, C, R | R2>;
16
+ };
17
+ //# sourceMappingURL=loopCauseEffect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"loopCauseEffect.d.ts","sourceRoot":"","sources":["../../../src/Fx/combinators/loopCauseEffect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAC;AAC3C,OAAO,KAAK,KAAK,MAAM,MAAM,eAAe,CAAC;AAI7C,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAEnC;;;;;;;;GAQG;AACH,eAAO,MAAM,eAAe,EAAE;IAC5B,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,EACb,IAAI,EAAE,CAAC,EACP,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,GAChF,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;IAElD,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,EAChB,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,EACjB,IAAI,EAAE,CAAC,EACP,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,GACnF,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;CASrB,CAAC"}