type alias Overflow

What a full channel does — the two GenStage :buffer_keep choices, named for the element that goes rather than the one that stays, plus the option of refusing to lose anything silently.

const keepNewest: Overflow = 'dropOldest'; // GenStage's :last, and the default
const keepOldest: Overflow = 'dropNewest'; // GenStage's :first
const refuse: Overflow = 'fail';           // stop the stream instead of dropping

Definition

"dropOldest" | "dropNewest" | "fail"

Usage

import { type Overflow } from "lib/stream/stream.ts";