@typed/stream
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

@typed/stream

Well-typed extensions to @most/core

Get it

yarn add @typed/stream
# or
npm install --save @typed/stream

API

filterMaybe<A>(maybe$: Stream<Maybe<A>>): Stream<A>

Filters out the Nothing values a stream of Maybes and unwraps the values of all Justs.

maybe$:             ---N---J(1)---N---J(1)---->
filterMaybe(maybe$):---------1----------1----->

splitEither<A, B>(either$: Stream<Either<A, B>>): [ Stream<A>, Stream<B> ]

Splits the values contained in an Either and produces 1 stream for the Left and 1 stream Right values.

either$: ---L(1)---R(2)---L(3)---R(4)--->
const [ left$, right$ ] = splitEither(either$)
left$:   -----1-------------3----------->
right$:  ------------2-------------4---->

Readme

Keywords

none

Package Sidebar

Install

npm i @typed/stream

Weekly Downloads

0

Version

1.1.0

License

MIT

Last publish

Collaborators

  • typed