This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export type bytes = number; | |
export class BlobStreamer { | |
protected readonly defaultChunkSize = 64 * 1024; // 64k (more is faster but makes chrome crash on large blobs?!) | |
private offset: bytes = 0; | |
constructor(private blob: Blob) { | |
this.rewind(); | |
} |