- add tests (property-based tests for monad laws?)
- change then method to flatMap
- support async
- catch method
- correct type restrictions on errors
- sequence and parallel functions
- race function
- finally method
- catchAll method for unsoundly throw errors
- wait function e.g.
.andThen(IO.wait(5, "seconds"))
- timeout method (implement in terms of
IO.race
?) - retry method
- exponential backoff for retry
- filter for retry
- Add Canceled to IOOutcome
- Add cancellation behaviour to run loop
- Add a way to interoperate with other cancellation mechanisms e.g.
clearTimeout
- Support async
cancel
callbacks forIO.cancelable
- Fiber.start function
- Fiber.cancel method
- Fiber.outcome method
- Rewrite
parallel
using fibers - Rewrite
race
using fibers - IO.cancel function for a fiber to self-cancel
-
IO.onCancel
method for resource cleanup - Add
IO.bracket
function for resource cleanup - Add a way to create uncancelable sections
- Ref
- Tests for Ref
- Deferred?
- Queue?
- Batcher?
- FiberPool - for limiting concurrency. Build on top of Queue?
- make recursive IO stack-safe
- optimise to avoid creation of unnecessary promises
- write some useful benchmarks - compare async/await/throw implementation to IO
- Re-use the
Wrap
,Raise
andCancel
class as the cases ofIOResult
to avoid allocations?
- work out how to split into several modules
- replace
IOInterface
andmethods
object with abstract base class - Use consistent terminology throughout - e.g. IO vs action vs effect
- Rename
IOResult
toOutcome
orIOOutcome
andIOOutcome
toOutcomeKind
- Refactor
IO
implementation to takeexecuteOn
as a private member rather than using inheritance. - Make type errors easier to understand by removing the massive union type.
- Remove duplication between implementations of IO.race and IO.parallel.
- lift function to return IO
- map method
- mapError method
- forEach method (and parallel equivalent)
-
.as
method - repeatForever method
- some more helper methods for composing independent IOs and returning the first or second value
- overload
andThen
to take anIO
instead of a() => IO
- Support for partial functions in catch and andThen?
- Set up documentation generator.
- Publish docs to GitHub pages.
- Add "Getting Started" guide to the readme.
- Ensure all important methods and functions have doc comments.
- Publish to NPM.