Skip to content

Commit

Permalink
Merge pull request #13 from styfle/patch-1
Browse files Browse the repository at this point in the history
Add Buffers to DIVERGENCES.md
  • Loading branch information
littledan committed Dec 24, 2018
2 parents f645e4b + d4f5c07 commit ead8455
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion DIVERGENCES.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ For interfaces to be considered analogous, there should be some evidence that de
- **Node.js API**: [Node Streams](https://nodejs.org/api/stream.html)
- **Mitigation strategies**: [whatwg-stream](https://github.com/nodejs/whatwg-stream) effort to implement WHATWG Streams as a Node.js module; [`readable-stream`](https://www.npmjs.com/package/readable-stream) provides Node streams for the Web

## Buffers

- **Purpose**: Interaction with octet streams
- **Web API**: [ArrayBuffer API](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer)
- **Node.js API** [Buffer API](https://nodejs.org/api/buffer.html)
- **Mitigation strategies**: Newer versions of Node.js have [Buffer.from(arrayBuffer)](https://nodejs.org/api/buffer.html#buffer_class_method_buffer_from_arraybuffer_byteoffset_length) method and the `Buffer` is an instance of a [TypedArray](https://nodejs.org/api/buffer.html#buffer_buffers_and_typedarray) with a few caveats.

## HTTP access

- **Purpose**: Open, read and write to an HTTP, HTTPS, HTTP2 connection
Expand All @@ -41,7 +48,7 @@ For interfaces to be considered analogous, there should be some evidence that de

## Cancel[l]ation

- **Purpose**: Provide APIs which cancel asynchronous processes, asynchronous requests, promises, etc.
- **Purpose**: Provide APIs which
- **Web API**: [AbortController](https://developer.mozilla.org/en-US/docs/Web/API/AbortController)
- **Node API**: ??
- **Mitigation strategies**: ??

0 comments on commit ead8455

Please sign in to comment.