-
-
Notifications
You must be signed in to change notification settings - Fork 35.6k
Start moving to Uint8Array in new APIs? #41588
Copy link
Copy link
Open
Labels
bufferIssues and PRs related to the buffer subsystem.Issues and PRs related to the buffer subsystem.discussIssues opened for discussions and feedbacks.Issues opened for discussions and feedbacks.
Metadata
Metadata
Assignees
Labels
bufferIssues and PRs related to the buffer subsystem.Issues and PRs related to the buffer subsystem.discussIssues opened for discussions and feedbacks.Issues opened for discussions and feedbacks.
Type
Fields
Give feedbackNo fields configured for issues without a type.
There was a suggestion by @jasnell to use
Uint8Arrays in new APIs overBuffers as well as a weigh-in by @sindresorhus saying it is easier to author cross-platform APIs when usingUint8Arrays.Here is a context #41553 (comment)
That is, the ask here is that Node.js should prefer
Uint8Arrays overBuffers in new APIs.What does everyone think? Should we stick to
Buffer(which is a subclass ofUint8Arrayas a reminder) or preferUint8Arrays over buffers when possible in new APIs?cc @nodejs/buffer @nodejs/streams