doc: add documentation for response.flushHeaders()

PR-URL: https://github.com/nodejs/node/pull/28807
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
Luigi Pinca 2019-07-22 17:30:20 +02:00 committed by Rich Trott
parent 10dd1012d9
commit 0d32b9de77

View File

@ -614,7 +614,7 @@ request was initiated via [`http.get()`][].
added: v1.6.0 added: v1.6.0
--> -->
Flush the request headers. Flushes the request headers.
For efficiency reasons, Node.js normally buffers the request headers until For efficiency reasons, Node.js normally buffers the request headers until
`request.end()` is called or the first chunk of request data is written. It `request.end()` is called or the first chunk of request data is written. It
@ -1185,6 +1185,13 @@ added: v0.0.2
The `response.finished` property will be `true` if [`response.end()`][] The `response.finished` property will be `true` if [`response.end()`][]
has been called. has been called.
### response.flushHeaders()
<!-- YAML
added: v1.6.0
-->
Flushes the response headers. See also: [`request.flushHeaders()`][].
### response.getHeader(name) ### response.getHeader(name)
<!-- YAML <!-- YAML
added: v0.4.0 added: v0.4.0
@ -2207,6 +2214,7 @@ not abort the request or do anything besides add a `'timeout'` event.
[`new URL()`]: url.html#url_constructor_new_url_input_base [`new URL()`]: url.html#url_constructor_new_url_input_base
[`removeHeader(name)`]: #http_request_removeheader_name [`removeHeader(name)`]: #http_request_removeheader_name
[`request.end()`]: #http_request_end_data_encoding_callback [`request.end()`]: #http_request_end_data_encoding_callback
[`request.flushHeaders()`]: #http_request_flushheaders
[`request.getHeader()`]: #http_request_getheader_name [`request.getHeader()`]: #http_request_getheader_name
[`request.setHeader()`]: #http_request_setheader_name_value [`request.setHeader()`]: #http_request_setheader_name_value
[`request.setTimeout()`]: #http_request_settimeout_timeout_callback [`request.setTimeout()`]: #http_request_settimeout_timeout_callback