UNPKG

@aptpod/iscp-ts

Version:

iSCP 2.0 client library for TypeScript

13 lines 412 B
export const concat = (...args) => { const totalByteLength = args.reduce((prev, cur) => { return prev + cur.byteLength; }, 0); const combinedArray = new Uint8Array(totalByteLength); let byteOffset = 0; for (const array of args) { combinedArray.set(array, byteOffset); byteOffset += array.byteLength; } return combinedArray; }; //# sourceMappingURL=index.js.map