Skip to content

Commit da499da

Browse files
committed
Improve first example.
1 parent c122a7d commit da499da

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const options = {
3535
// Create a Readable stream from the Encoder.
3636
// You can omit usage of `Readable.from` for HTTP clients whose support async iterables.
3737
// The Encoder will yield FormData content portions encoded into the multipart/form-data format as node-fetch consumes the stream.
38-
body: Readable.from(encoder)
38+
body: Readable.from(encoder.encode()) // or Readable.from(encoder)
3939
}
4040

4141
const response = await fetch("https://httpbin.org/post", options)

0 commit comments

Comments
 (0)