/** * Returns an effect that effectfully "peeks" at the success of this effect. * * @tsplus static effect/core/io/Effect.Aspects tap * @tsplus pipeable effect/core/io/Effect tap */ export function tap(f: (a: A) => Effect) { return (self: Effect): Effect => self.flatMap((a: A) => f(a).map(() => a)) }