@types/node 18.19.79 → 18.19.81
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- node v18.19/README.md +1 -1
- node v18.19/constants.d.ts +14 -12
- node v18.19/http.d.ts +2 -2
- node v18.19/os.d.ts +7 -0
- node v18.19/package.json +2 -2
- node v18.19/process.d.ts +27 -0
node v18.19/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for node (https://nodejs.org/).
|
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node/v18.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Fri, 21 Mar 2025 09:02:30 GMT
|
|
12
12
|
* Dependencies: [undici-types](https://npmjs.com/package/undici-types)
|
|
13
13
|
|
|
14
14
|
# Credits
|
node v18.19/constants.d.ts
CHANGED
|
@@ -1,16 +1,18 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/**
|
|
2
|
+
* @deprecated The `node:constants` module is deprecated. When requiring access to constants
|
|
3
|
+
* relevant to specific Node.js builtin modules, developers should instead refer
|
|
4
|
+
* to the `constants` property exposed by the relevant module. For instance,
|
|
5
|
+
* `require('node:fs').constants` and `require('node:os').constants`.
|
|
6
|
+
*/
|
|
2
7
|
declare module "constants" {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
& typeof
|
|
9
|
-
& typeof
|
|
10
|
-
|
|
11
|
-
& typeof cryptoConstants
|
|
12
|
-
& typeof fsConstants;
|
|
13
|
-
export = exp;
|
|
8
|
+
const constants:
|
|
9
|
+
& typeof import("node:os").constants.dlopen
|
|
10
|
+
& typeof import("node:os").constants.errno
|
|
11
|
+
& typeof import("node:os").constants.priority
|
|
12
|
+
& typeof import("node:os").constants.signals
|
|
13
|
+
& typeof import("node:fs").constants
|
|
14
|
+
& typeof import("node:crypto").constants;
|
|
15
|
+
export = constants;
|
|
14
16
|
}
|
|
15
17
|
|
|
16
18
|
declare module "node:constants" {
|
node v18.19/http.d.ts
CHANGED
|
@@ -341,8 +341,8 @@ declare module "http" {
|
|
|
341
341
|
* @since v0.9.12
|
|
342
342
|
* @param [msecs=0 (no timeout)]
|
|
343
343
|
*/
|
|
344
|
-
setTimeout(msecs?: number, callback?: () => void): this;
|
|
345
|
-
setTimeout(callback: () => void): this;
|
|
344
|
+
setTimeout(msecs?: number, callback?: (socket: Socket) => void): this;
|
|
345
|
+
setTimeout(callback: (socket: Socket) => void): this;
|
|
346
346
|
/**
|
|
347
347
|
* Limits maximum incoming headers count. If set to 0, no limit will be applied.
|
|
348
348
|
* @since v0.7.0
|
node v18.19/os.d.ts
CHANGED
|
@@ -382,6 +382,13 @@ declare module "os" {
|
|
|
382
382
|
const WSA_E_CANCELLED: number;
|
|
383
383
|
const WSAEREFUSED: number;
|
|
384
384
|
}
|
|
385
|
+
namespace dlopen {
|
|
386
|
+
const RTLD_LAZY: number;
|
|
387
|
+
const RTLD_NOW: number;
|
|
388
|
+
const RTLD_GLOBAL: number;
|
|
389
|
+
const RTLD_LOCAL: number;
|
|
390
|
+
const RTLD_DEEPBIND: number;
|
|
391
|
+
}
|
|
385
392
|
namespace priority {
|
|
386
393
|
const PRIORITY_LOW: number;
|
|
387
394
|
const PRIORITY_BELOW_NORMAL: number;
|
node v18.19/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "18.19.
|
|
3
|
+
"version": "18.19.81",
|
|
4
4
|
"description": "TypeScript definitions for node",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
|
|
6
6
|
"license": "MIT",
|
|
@@ -220,6 +220,6 @@
|
|
|
220
220
|
"undici-types": "~5.26.4"
|
|
221
221
|
},
|
|
222
222
|
"peerDependencies": {},
|
|
223
|
-
"typesPublisherContentHash": "
|
|
223
|
+
"typesPublisherContentHash": "7167399ff531535bed98774412a3fe6f50b69c4aeb5beaccf1b156435cfa2581",
|
|
224
224
|
"typeScriptVersion": "5.0"
|
|
225
225
|
}
|
node v18.19/process.d.ts
CHANGED
|
@@ -509,6 +509,33 @@ declare module "process" {
|
|
|
509
509
|
* @since v0.7.2
|
|
510
510
|
*/
|
|
511
511
|
debugPort: number;
|
|
512
|
+
/**
|
|
513
|
+
* The `process.dlopen()` method allows dynamically loading shared objects. It is primarily used by `require()` to load C++ Addons, and
|
|
514
|
+
* should not be used directly, except in special cases. In other words, `require()` should be preferred over `process.dlopen()`
|
|
515
|
+
* unless there are specific reasons such as custom dlopen flags or loading from ES modules.
|
|
516
|
+
*
|
|
517
|
+
* The `flags` argument is an integer that allows to specify dlopen behavior. See the `[os.constants.dlopen](https://nodejs.org/docs/latest-v20.x/api/os.html#dlopen-constants)`
|
|
518
|
+
* documentation for details.
|
|
519
|
+
*
|
|
520
|
+
* An important requirement when calling `process.dlopen()` is that the `module` instance must be passed. Functions exported by the C++ Addon
|
|
521
|
+
* are then accessible via `module.exports`.
|
|
522
|
+
*
|
|
523
|
+
* The example below shows how to load a C++ Addon, named `local.node`, that exports a `foo` function. All the symbols are loaded before the call returns, by passing the `RTLD_NOW` constant.
|
|
524
|
+
* In this example the constant is assumed to be available.
|
|
525
|
+
*
|
|
526
|
+
* ```js
|
|
527
|
+
* import { dlopen } from 'node:process';
|
|
528
|
+
* import { constants } from 'node:os';
|
|
529
|
+
* import { fileURLToPath } from 'node:url';
|
|
530
|
+
*
|
|
531
|
+
* const module = { exports: {} };
|
|
532
|
+
* dlopen(module, fileURLToPath(new URL('local.node', import.meta.url)),
|
|
533
|
+
* constants.dlopen.RTLD_NOW);
|
|
534
|
+
* module.exports.foo();
|
|
535
|
+
* ```
|
|
536
|
+
* @since v0.1.16
|
|
537
|
+
*/
|
|
538
|
+
dlopen(module: object, filename: string, flags?: number): void;
|
|
512
539
|
/**
|
|
513
540
|
* The `process.emitWarning()` method can be used to emit custom or application
|
|
514
541
|
* specific process warnings. These can be listened for by adding a handler to the `'warning'` event.
|