Skip to content

Commit 796355e

Browse files
committed
doc: add description for the listener argument
Clarify that `listener` is registered as a one-time listener of the `'connect'` event. Fixes: #28217
1 parent 26b048e commit 796355e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

doc/api/http2.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -2208,7 +2208,8 @@ changes:
22082208
instance passed to `connect` and the `options` object, and returns any
22092209
[`Duplex`][] stream that is to be used as the connection for this session.
22102210
* ...: Any [`net.connect()`][] or [`tls.connect()`][] options can be provided.
2211-
* `listener` {Function}
2211+
* `listener` {Function} Will be registered as a one-time listener of the
2212+
[`'connect'`][] event.
22122213
* Returns: {ClientHttp2Session}
22132214

22142215
Returns a `ClientHttp2Session` instance.
@@ -3467,6 +3468,7 @@ following additional properties:
34673468
[Stream]: stream.html#stream_stream
34683469
[Using `options.selectPadding()`]: #http2_using_options_selectpadding
34693470
[`'checkContinue'`]: #http2_event_checkcontinue
3471+
[`'connect'`]: #http2_event_connect
34703472
[`'request'`]: #http2_event_request
34713473
[`'unknownProtocol'`]: #http2_event_unknownprotocol
34723474
[`ClientHttp2Stream`]: #http2_class_clienthttp2stream

0 commit comments

Comments
 (0)