Documentation
    Preparing search index...

    Function withCounter

    • Adds a counter representing the amount of chunks received thus far.

      Type Parameters

      • T

      Parameters

      • start: number = 0

      Returns TransformStream<T, { chunk: T; counter: number }>

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

      withCounter()

      --{chunk:'a',counter:0}--{chunk:'b',counter:1}-|