MCPcopy Create free account
hub / github.com/Effect-TS/effect / option

Function option

packages/effect/src/Micro.ts:2923–2924  ·  view source on GitHub ↗
(self: Micro<A, E, R>)

Source from the content-addressed store, hash-verified

2921 * @category error handling
2922 */
2923export const option = <A, E, R>(self: Micro<A, E, R>): Micro<Option.Option<A>, never, R> =>
2924 match(self, { onFailure: Option.none, onSuccess: Option.some })
2925
2926/**
2927 * Replace the success value of the given `Micro` effect with an `Either`,

Callers

nothing calls this directly

Calls 1

matchFunction · 0.70

Tested by

no test coverage detected