UNPKG

@gmod/bgzf-filehandle

Version:

read from a compressed bgzip file (with .gzi) as if it were uncompressed

14 lines (13 loc) 311 B
export function concatUint8Array(args: Uint8Array[]) { let total = 0 for (const entry of args) { total += entry.length } const mergedArray = new Uint8Array(total) let offset = 0 for (const entry of args) { mergedArray.set(entry, offset) offset += entry.length } return mergedArray }