@adviser/cement - v0.0.0
    Preparing search index...

    Function concatUint8

    • Concatenates multiple Uint8Arrays into a single Uint8Array.

      Allocates a single buffer and copies each array into it, which is more efficient than spread-based approaches for many or large arrays.

      Parameters

      • ...arrays: Uint8Array<ArrayBufferLike>[]

        Zero or more Uint8Arrays to concatenate

      Returns Uint8Array

      A new Uint8Array containing all bytes in order

      const a = new Uint8Array([1, 2, 3]);
      const b = new Uint8Array([4, 5]);
      const c = new Uint8Array([6]);

      concatUint8(a, b, c); // Uint8Array([1, 2, 3, 4, 5, 6])
      concatUint8(); // Uint8Array([])
      concatUint8(a); // Uint8Array([1, 2, 3])