Package: effect
Module: Channel
Represents strategies for halting merged channels when one completes or fails.
Example (Choosing merge halt strategies)
import type { Channel } from "effect"
// Different halt strategies for channel merging
const leftFirst: Channel.HaltStrategy = "left" // Stop when left channel halts
const rightFirst: Channel.HaltStrategy = "right" // Stop when right channel halts
const both: Channel.HaltStrategy = "both" // Stop when both channels halt
const either: Channel.HaltStrategy = "either" // Stop when either channel halts
Signature
type HaltStrategy = "left" | "right" | "both" | "either"
Since v4.0.0