Skip to content

feat: Support sindresorhus's got response stream - #562

Open
h16rkim wants to merge 5 commits into
form-data:masterfrom
h16rkim:got-response-stream
Open

feat: Support sindresorhus's got response stream#562
h16rkim wants to merge 5 commits into
form-data:masterfrom
h16rkim:got-response-stream

Conversation

@h16rkim

@h16rkim h16rkim commented Apr 4, 2024

Copy link
Copy Markdown

Added Support for sindresorhus's got stream response

Until now, form-data supports Node.js http-response stream and mikeal's request stream.

With this PR, we can use form-data with sindresorhus's got stream response.

import got from 'got';
import FormData from 'form-data';

var form = new FormData();

form.append('my_field', 'my value');
form.append('my_buffer', new Buffer(10));
form.append('my_logo', got.stream('http://nodejs.org/images/logo.png'));

Closes #522

@h16rkim h16rkim changed the title feat: Support Got response stream feat: Support sindresorhus's Got response stream Apr 4, 2024

@dleo9307 dleo9307 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@h16rkim h16rkim changed the title feat: Support sindresorhus's Got response stream feat: Support sindresorhus's got response stream Apr 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

how the stream from 'got' Lib use for form-data?

2 participants