Skip to content
Effect 4.0 is here. One ecosystem. Zero dependencies.

Readable

8 exports Since v2.0.0 Source

Combinators

Since v2.0.0

Signature

declare const map: {
<A, B>(f: (a: NoInfer<A>) => B): <E, R>(fa: Readable<A, E, R>) => Readable<B, E, R>;
<A, E, R, B>(self: Readable<A, E, R>, f: (a: NoInfer<A>) => B): Readable<B, E, R>;
}

Signature

declare const mapEffect: {
<A, B, E2, R2>(f: (a: NoInfer<A>) => Effect<B, E2, R2>): <E, R>(fa: Readable<A, E, R>) => Readable<B, E2 | E, R2 | R>;
<A, E, R, B, E2, R2>(self: Readable<A, E, R>, f: (a: NoInfer<A>) => Effect<B, E2, R2>): Readable<B, E | E2, R | R2>;
}

Constructors

Since v2.0.0

Signature

declare function make<A, E, R>(get: Effect<A, E, R>): Readable<A, E, R>
Since v2.0.0

Signature

declare function unwrap<A, E, R, E1, R1>(effect: Effect<Readable<A, E, R>, E1, R1>): Readable<A, E | E1, R | R1>

Models

Readable

interface
Since v2.0.0

Signature

interface Readable<A, E = never, R = never> extends Pipeable {
readonly [TypeId]: typeof TypeId;
readonly get: Effect<A, E, R>;
}

Refinements

Signature

declare function isReadable(u: unknown): u is Readable<unknown, unknown, unknown>

Type Ids

Since v2.0.0

Signature

declare const TypeId: unique symbol
Since v2.0.0

Signature

type TypeId = typeof TypeId