@gmod/cram
Version:
read CRAM files with pure Javascript
17 lines • 405 B
JavaScript
function sum(array) {
let sum = 0;
for (const entry of array) {
sum += entry.length;
}
return sum;
}
export function concatUint8Array(args) {
const mergedArray = new Uint8Array(sum(args));
let offset = 0;
for (const entry of args) {
mergedArray.set(entry, offset);
offset += entry.length;
}
return mergedArray;
}
//# sourceMappingURL=util.js.map