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

Function transformOrFail

packages/effect/src/SchemaGetter.ts:561–565  ·  view source on GitHub ↗
(
  f: (e: E, options: SchemaAST.ParseOptions) => Effect.Effect<T, SchemaIssue.Issue, R>
)

Source from the content-addressed store, hash-verified

559 * @since 4.0.0
560 */
561export function transformOrFail<T, E, R = never>(
562 f: (e: E, options: SchemaAST.ParseOptions) => Effect.Effect<T, SchemaIssue.Issue, R>
563): Getter<T, E, R> {
564 return onSome((e, options) => f(e, options).pipe(Effect.mapEager(Option.some)))
565}
566
567/**
568 * Creates a getter that transforms the full `Option` — both present and absent values.

Callers 8

decodeBase64Function · 0.70
decodeBase64StringFunction · 0.70
decodeBase64UrlFunction · 0.70
decodeBase64UrlStringFunction · 0.70
decodeHexFunction · 0.70
decodeHexStringFunction · 0.70
decodeUriComponentFunction · 0.70
dateTimeUtcFromInputFunction · 0.70

Calls 3

onSomeFunction · 0.70
pipeMethod · 0.65
fFunction · 0.50

Tested by

no test coverage detected