Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ed91379

Browse filesBrowse files
micromaomaodanielleadams
authored andcommitted
doc: clearify that http does chunked encoding itself
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com> PR-URL: #28379 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
1 parent 92ed1c6 commit ed91379
Copy full SHA for ed91379

File tree

Expand file treeCollapse file tree

1 file changed

+5
-5
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+5
-5
lines changed
Open diff view settings
Collapse file

‎doc/api/http.md‎

Copy file name to clipboardExpand all lines: doc/api/http.md
+5-5Lines changed: 5 additions & 5 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -1027,11 +1027,11 @@ added: v0.1.29
10271027
* `callback` {Function}
10281028
* Returns: {boolean}
10291029

1030-
Sends a chunk of the body. By calling this method
1031-
many times, a request body can be sent to a
1032-
server. In that case, it is suggested to use the
1033-
`['Transfer-Encoding', 'chunked']` header line when
1034-
creating the request.
1030+
Sends a chunk of the body. This method can be called multiple times. If no
1031+
`Content-Length` is set, data will automatically be encoded in HTTP Chunked
1032+
transfer encoding, so that server knows when the data ends. The
1033+
`Transfer-Encoding: chunked` header is added. Calling [`request.end()`][]
1034+
is necessary to finish sending the request.
10351035

10361036
The `encoding` argument is optional and only applies when `chunk` is a string.
10371037
Defaults to `'utf8'`.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.