Re: [whatwg/streams] Add Explainer for Byte Streams (#1081)

@ricea commented on this pull request.

lgtm with one suggestion for improvement. Let's wait for @domenic to take a look.

> +readers can reduce the number of times we run garbage collection, because we can reuse buffers.
+
+
+## Examples
+
+These are a few examples of Javascript which can be used for byte streams once this is implemented:
+
+
+### Reading bytes from the stream into a single memory buffer
+
+The code reads the first 1024 bytes from the stream into a single memory buffer. This is due to the fact that if a
+stream is a readable byte stream, you can also acquire a BYOB reader for it, which allows more precise control over
+buffer allocation in order to avoid copies.
+
+
+```

You can use \`\`\`javascript to cause the example to be highlighted as JavaScript.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/streams/pull/1081#pullrequestreview-518759806

Received on Wednesday, 28 October 2020 15:01:27 UTC