destroy-on-hwm1.0.0 • Public • Published
Destroys a writable stream if a write ever hits the high water mark. This is useful when piping a single stream to multiple clients - you don't want one client slowing down the rest of the clients. With how streams currently work, streams flow at the speed of the slowest destination stream.
var Stream = ;var destroyOnHWM = ;var stream = ;/*** With no callback, attempts to execute `stream.destroy()` on high water mark.* This stream does not have `.destroy()` though, so it's really a noop.*/;/*** Instead, we'll just use a custom callback.*/;