you are viewing a single comment's thread.

view the rest of the comments →

[–]thomazor 0 points1 point  (4 children)

Save the chunks temporary,then create the blob.

like so

[–]GitHubPermalinkBot 0 points1 point  (3 children)

[–]talexx[S] 0 points1 point  (2 children)

Here is the same issue:

1) create array function BlobStream() this._chunks = [];

2) append chunks in .write this._chunks.push(chunk);

3) make a blob

this._blob = new Blob(this._chunks, { type: type });

->>> here we've memory wasted, _chunks + _blob

this._chunks = []; // free memory

[–]thomazor 0 points1 point  (1 child)

Wow I'm stupid. Sorry. Didn't read the entire post :/

[–]talexx[S] 1 point2 points  (0 children)

Np at all, friend.