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

Function toPredicate

packages/effect/src/Filter.ts:262–265  ·  view source on GitHub ↗
(
  self: Filter<A, Pass, Fail>
)

Source from the content-addressed store, hash-verified

260 * @since 4.0.0
261 */
262export const toPredicate = <A, Pass, Fail>(
263 self: Filter<A, Pass, Fail>
264): Predicate.Predicate<A> =>
265(input: A) => !Result.isFailure(self(input))
266
267/**
268 * A predefined filter that only passes through string values.

Callers

nothing calls this directly

Calls 1

selfFunction · 0.85

Tested by

no test coverage detected