/** * Runs both sinks in parallel on the input, , returning the result or the * error from the one that finishes first. * * @tsplus static effect/core/stream/Sink.Aspects race * @tsplus pipeable effect/core/stream/Sink race */ export function race(that: Sink) { return ( self: Sink ): Sink => self.raceBoth(that).map((either) => either.merge) }