Skip to content

Allow ArrayBuffer and related views as data#10

Merged
mzabriskie merged 1 commit intoaxios:masterfrom
mathbruyen:arraybuffer
Sep 18, 2014
Merged

Allow ArrayBuffer and related views as data#10
mzabriskie merged 1 commit intoaxios:masterfrom
mathbruyen:arraybuffer

Conversation

@mathbruyen
Copy link
Copy Markdown

In order to push binary data under the form of ArrayBuffer and its related views (Int8Array, ...) one needs not to stringify those.

For the XHR adapter there is nothing to do as it natively supports ArrayBuffer view in req.send().

Node's http adapter supports only string or Buffer thus a transformation to Buffer is required before setting content length header.

In order to push binary data under the form of ArrayBuffer and
its related views (Int8Array, ...) one needs not to stringify
those.

For the XHR adapter there is nothing to do as it natively supports
ArrayBuffer in req.send().

Node's http adapter supports only string or Buffer thus a
transformation to Buffer is required before setting content length
header.
mzabriskie added a commit that referenced this pull request Sep 18, 2014
Allow ArrayBuffer and related views as data
@mzabriskie mzabriskie merged commit c03e51c into axios:master Sep 18, 2014
@mzabriskie
Copy link
Copy Markdown
Member

@mathbruyen thank you for the pull requests!

@mathbruyen mathbruyen deleted the arraybuffer branch September 18, 2014 19:32
@mathbruyen
Copy link
Copy Markdown
Author

You're welcome, thanks for merging!

@axios axios locked and limited conversation to collaborators May 4, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants