Documentation
    Preparing search index...

    Function interpose

    • Hold up a stream until a promise resolves. If it errors, the error will be emitted to the stream.

      Type Parameters

      • T

      Parameters

      • promise: Promise<void> | ((chunk: T) => Promise<void>)

      Returns TransformStream<T, T>

      ----a-------b------|

      interpose(async () => await setTimeout(50))

      --------a--------b-|