doc: fix linter issues

PR-URL: https://github.com/nodejs/node/pull/60636
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
This commit is contained in:
Antoine du Hamel 2025-11-08 18:09:29 +01:00
parent 5cc79d8945
commit 7011736703
No known key found for this signature in database
GPG Key ID: 20B1A390B168D356
3 changed files with 11 additions and 13 deletions

View File

@ -250,19 +250,19 @@ added: v0.11.4
Produces a socket/stream to be used for HTTP requests.
By default, this function behaves identically to [`net.createConnection(options)`][],
By default, this function behaves identically to [`net.createConnection()`][],
synchronously returning the created socket. The optional `callback` parameter in the
signature is **not** used by this default implementation.
However, custom agents may override this method to provide greater flexibility,
for example, to create sockets asynchronously. When overriding `createConnection`:
1. **Synchronous socket creation**: The overriding method can return the
socket/stream directly.
2. **Asynchronous socket creation**: The overriding method can accept the `callback`
and pass the created socket/stream to it (e.g., `callback(null, newSocket)`).
If an error occurs during socket creation, it should be passed as the first
argument to the `callback` (e.g., `callback(err)`).
1. **Synchronous socket creation**: The overriding method can return the
socket/stream directly.
2. **Asynchronous socket creation**: The overriding method can accept the `callback`
and pass the created socket/stream to it (e.g., `callback(null, newSocket)`).
If an error occurs during socket creation, it should be passed as the first
argument to the `callback` (e.g., `callback(err)`).
The agent will call the provided `createConnection` function with `options` and
this internal `callback`. The `callback` provided by the agent has a signature

View File

@ -64,7 +64,7 @@ An [`Agent`][] object for HTTPS similar to [`http.Agent`][]. See
Like `http.Agent`, the `createConnection(options[, callback])` method can be overridden
to customize how TLS connections are established.
> See [`http.Agent#createConnection()`][] for details on overriding this method,
> See [`agent.createConnection()`][] for details on overriding this method,
> including asynchronous socket creation with a callback.
### `new Agent([options])`
@ -742,6 +742,7 @@ statusCode: 200
[`Agent`]: #class-httpsagent
[`Session Resumption`]: tls.md#session-resumption
[`URL`]: url.md#the-whatwg-url-api
[`agent.createConnection()`]: http.md#agentcreateconnectionoptions-callback
[`http.Agent(options)`]: http.md#new-agentoptions
[`http.Agent`]: http.md#class-httpagent
[`http.ClientRequest`]: http.md#class-httpclientrequest

View File

@ -4,17 +4,14 @@ This file documents various terms and definitions used throughout the Node.js co
* **ABI**: [Application Binary Interface][] - Defines the interface between two binary program modules.
* **AFAICT**: As Far As I Can Tell.
* **AFAICT**: As Far As I Can Tell.
* **AFAIK**: As Far As I Know.
* **AFAIK**: As Far As I Know.
* **API**: [Application Programming Interface][] - A set of rules and protocols that allows different software
applications to communicate with each other. APIs are used to enable integration between different systems.
* **ASAP**: As Soon As Possible.
* **ASLR**: Address Space Layout Randomization. A security technique that randomizes memory addresses to prevent certain attacks.
* **ASLR**: Address Space Layout Randomization. A security technique that randomizes memory addresses
to prevent certain attacks.
* **Backport**: The process of applying a fix or feature from a newer branch to an older supported
branch (e.g., applying a security fix to an LTS release).
* **BE** ([Big Endian]): Byte order in which the most significant byte is stored first in memory.
Opposite of **LE** (Little Endian).
* **BE**: Big [Endian][] - A Byte Order where the largest bit comes first. The opposite of **LE**.
* **Bootstrap**: Early phase in the Node.js process startup - sets up the execution environment and loads internal
modules.