(writer: Writer, data: Uint8Array)
| 29 | * @param data The data to write |
| 30 | */ |
| 31 | export async function writeAll(writer: Writer, data: Uint8Array) { |
| 32 | let nwritten = 0; |
| 33 | while (nwritten < data.length) { |
| 34 | nwritten += await writer.write(data.subarray(nwritten)); |
| 35 | } |
| 36 | } |
| 37 | |
| 38 | /** |
| 39 | * Synchronously write all the content of the array buffer (`arr`) to the |
no test coverage detected