@emulsify/cli 1.11.4 → 1.12.0
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.
- package/dist/node_modules/.package-lock.json +34 -24
- package/dist/node_modules/@types/node/README.md +2 -2
- package/dist/node_modules/@types/node/assert.d.ts +23 -1
- package/dist/node_modules/@types/node/async_hooks.d.ts +64 -0
- package/dist/node_modules/@types/node/buffer.buffer.d.ts +124 -38
- package/dist/node_modules/@types/node/buffer.d.ts +19 -17
- package/dist/node_modules/@types/node/child_process.d.ts +88 -161
- package/dist/node_modules/@types/node/cluster.d.ts +5 -6
- package/dist/node_modules/@types/node/constants.d.ts +14 -12
- package/dist/node_modules/@types/node/crypto.d.ts +237 -166
- package/dist/node_modules/@types/node/dgram.d.ts +15 -14
- package/dist/node_modules/@types/node/diagnostics_channel.d.ts +39 -15
- package/dist/node_modules/@types/node/dns/promises.d.ts +11 -9
- package/dist/node_modules/@types/node/dns.d.ts +28 -21
- package/dist/node_modules/@types/node/events.d.ts +81 -35
- package/dist/node_modules/@types/node/fs/promises.d.ts +61 -36
- package/dist/node_modules/@types/node/fs.d.ts +251 -193
- package/dist/node_modules/@types/node/globals.d.ts +146 -442
- package/dist/node_modules/@types/node/globals.typedarray.d.ts +17 -0
- package/dist/node_modules/@types/node/http.d.ts +136 -31
- package/dist/node_modules/@types/node/http2.d.ts +102 -26
- package/dist/node_modules/@types/node/https.d.ts +94 -60
- package/dist/node_modules/@types/node/index.d.ts +5 -3
- package/dist/node_modules/@types/node/{inspector.d.ts → inspector.generated.d.ts} +272 -2
- package/dist/node_modules/@types/node/module.d.ts +362 -138
- package/dist/node_modules/@types/node/net.d.ts +27 -20
- package/dist/node_modules/@types/node/os.d.ts +14 -3
- package/dist/node_modules/@types/node/package.json +4 -89
- package/dist/node_modules/@types/node/perf_hooks.d.ts +37 -10
- package/dist/node_modules/@types/node/process.d.ts +108 -35
- package/dist/node_modules/@types/node/querystring.d.ts +2 -3
- package/dist/node_modules/@types/node/readline/promises.d.ts +1 -1
- package/dist/node_modules/@types/node/stream/consumers.d.ts +33 -7
- package/dist/node_modules/@types/node/stream/web.d.ts +13 -4
- package/dist/node_modules/@types/node/stream.d.ts +963 -1014
- package/dist/node_modules/@types/node/string_decoder.d.ts +2 -2
- package/dist/node_modules/@types/node/test.d.ts +1504 -1655
- package/dist/node_modules/@types/node/timers/promises.d.ts +28 -17
- package/dist/node_modules/@types/node/timers.d.ts +157 -111
- package/dist/node_modules/@types/node/tls.d.ts +105 -67
- package/dist/node_modules/@types/node/ts5.6/buffer.buffer.d.ts +120 -37
- package/dist/node_modules/@types/node/ts5.6/globals.typedarray.d.ts +15 -0
- package/dist/node_modules/@types/node/ts5.6/index.d.ts +5 -3
- package/dist/node_modules/@types/node/url.d.ts +10 -1
- package/dist/node_modules/@types/node/util.d.ts +28 -3
- package/dist/node_modules/@types/node/v8.d.ts +6 -5
- package/dist/node_modules/@types/node/vm.d.ts +147 -68
- package/dist/node_modules/@types/node/wasi.d.ts +1 -1
- package/dist/node_modules/@types/node/web-globals/abortcontroller.d.ts +34 -0
- package/dist/node_modules/@types/node/web-globals/domexception.d.ts +68 -0
- package/dist/node_modules/@types/node/web-globals/events.d.ts +97 -0
- package/dist/node_modules/@types/node/web-globals/fetch.d.ts +46 -0
- package/dist/node_modules/@types/node/worker_threads.d.ts +60 -39
- package/dist/node_modules/@types/node/zlib.d.ts +21 -20
- package/dist/node_modules/debug/package.json +7 -3
- package/dist/node_modules/debug/src/browser.js +2 -1
- package/dist/node_modules/debug/src/common.js +57 -39
- package/dist/node_modules/fast-uri/.github/dependabot.yml +1 -1
- package/dist/node_modules/fast-uri/.github/workflows/ci.yml +81 -3
- package/dist/node_modules/fast-uri/.github/workflows/package-manager-ci.yml +6 -2
- package/dist/node_modules/fast-uri/LICENSE +3 -1
- package/dist/node_modules/fast-uri/README.md +55 -37
- package/dist/node_modules/fast-uri/benchmark/benchmark.mjs +159 -0
- package/dist/node_modules/fast-uri/benchmark/equal.mjs +51 -0
- package/dist/node_modules/fast-uri/benchmark/non-simple-domain.mjs +22 -0
- package/dist/node_modules/fast-uri/benchmark/package.json +17 -0
- package/dist/node_modules/fast-uri/benchmark/string-array-to-hex-stripped.mjs +24 -0
- package/dist/node_modules/fast-uri/benchmark/ws-is-secure.mjs +65 -0
- package/dist/node_modules/fast-uri/eslint.config.js +6 -0
- package/dist/node_modules/fast-uri/index.js +98 -61
- package/dist/node_modules/fast-uri/lib/schemes.js +160 -81
- package/dist/node_modules/fast-uri/lib/utils.js +217 -123
- package/dist/node_modules/fast-uri/package.json +44 -14
- package/dist/node_modules/fast-uri/test/ajv.test.js +7 -3
- package/dist/node_modules/fast-uri/test/equal.test.js +7 -2
- package/dist/node_modules/fast-uri/test/fixtures/uri-js-parse.json +501 -0
- package/dist/node_modules/fast-uri/test/fixtures/uri-js-serialize.json +120 -0
- package/dist/node_modules/fast-uri/test/parse.test.js +31 -31
- package/dist/node_modules/fast-uri/test/resolve.test.js +52 -49
- package/dist/node_modules/fast-uri/test/rfc-3986.test.js +90 -0
- package/dist/node_modules/fast-uri/test/serialize.test.js +55 -47
- package/dist/node_modules/fast-uri/test/uri-js-compatibility.test.js +33 -0
- package/dist/node_modules/fast-uri/test/uri-js.test.js +230 -230
- package/dist/node_modules/fast-uri/test/util.test.js +23 -8
- package/dist/node_modules/fast-uri/tsconfig.json +9 -0
- package/dist/node_modules/fast-uri/types/index.d.ts +16 -9
- package/dist/node_modules/fast-uri/types/index.test-d.ts +9 -9
- package/dist/node_modules/fs-extra/LICENSE +1 -1
- package/dist/node_modules/fs-extra/README.md +3 -1
- package/dist/node_modules/fs-extra/lib/copy/copy-sync.js +11 -1
- package/dist/node_modules/fs-extra/lib/copy/copy.js +13 -15
- package/dist/node_modules/fs-extra/lib/fs/index.js +6 -0
- package/dist/node_modules/fs-extra/lib/util/async.js +29 -0
- package/dist/node_modules/fs-extra/lib/util/stat.js +2 -1
- package/dist/node_modules/fs-extra/package.json +1 -1
- package/dist/node_modules/jsonfile/README.md +1 -1
- package/dist/node_modules/jsonfile/index.js +3 -3
- package/dist/node_modules/jsonfile/package.json +1 -1
- package/dist/node_modules/simple-git/dist/cjs/index.js +235 -235
- package/dist/node_modules/simple-git/dist/cjs/index.js.map +3 -3
- package/dist/node_modules/simple-git/dist/esm/index.js +229 -233
- package/dist/node_modules/simple-git/dist/esm/index.js.map +3 -3
- package/dist/node_modules/simple-git/dist/src/lib/git-logger.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/parsers/parse-branch.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/plugins/error-detection.plugin.d.ts +2 -3
- package/dist/node_modules/simple-git/dist/src/lib/plugins/simple-git-plugin.d.ts +2 -3
- package/dist/node_modules/simple-git/dist/src/lib/plugins/spawn-options-plugin.d.ts +0 -1
- package/dist/node_modules/simple-git/dist/src/lib/runners/scheduler.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/runners/tasks-pending-queue.d.ts +2 -2
- package/dist/node_modules/simple-git/dist/src/lib/tasks/apply-patch.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/tasks/clean.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/tasks/clone.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/tasks/log.d.ts +3 -3
- package/dist/node_modules/simple-git/dist/src/lib/tasks/push.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/tasks/remote.d.ts +4 -2
- package/dist/node_modules/simple-git/dist/src/lib/tasks/reset.d.ts +3 -3
- package/dist/node_modules/simple-git/dist/src/lib/tasks/stash-list.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/tasks/task.d.ts +2 -2
- package/dist/node_modules/simple-git/dist/src/lib/types/handlers.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/types/index.d.ts +9 -13
- package/dist/node_modules/simple-git/dist/src/lib/types/tasks.d.ts +5 -6
- package/dist/node_modules/simple-git/dist/src/lib/utils/argument-filters.d.ts +5 -7
- package/dist/node_modules/simple-git/dist/src/lib/utils/git-output-streams.d.ts +0 -1
- package/dist/node_modules/simple-git/dist/src/lib/utils/line-parser.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/utils/task-options.d.ts +1 -1
- package/dist/node_modules/simple-git/dist/src/lib/utils/util.d.ts +11 -10
- package/dist/node_modules/simple-git/package.json +6 -6
- package/dist/node_modules/simple-git/readme.md +8 -0
- package/dist/node_modules/undici-types/dispatcher.d.ts +1 -0
- package/dist/node_modules/undici-types/eventsource.d.ts +0 -2
- package/dist/node_modules/undici-types/filereader.d.ts +1 -1
- package/dist/node_modules/undici-types/interceptors.d.ts +3 -1
- package/dist/node_modules/undici-types/package.json +1 -1
- package/dist/node_modules/undici-types/patch.d.ts +0 -38
- package/dist/node_modules/undici-types/readable.d.ts +5 -0
- package/dist/node_modules/undici-types/webidl.d.ts +6 -0
- package/dist/node_modules/undici-types/websocket.d.ts +0 -2
- package/dist/package-lock.json +911 -812
- package/dist/package.json +1 -1
- package/dist/util/getAvailableStarters.js +2 -2
- package/package.json +1 -1
- package/dist/node_modules/@types/node/dom-events.d.ts +0 -124
- package/dist/node_modules/fast-uri/benchmark.js +0 -105
- package/dist/node_modules/fast-uri/lib/scopedChars.js +0 -30
- package/dist/node_modules/fast-uri/test/.gitkeep +0 -0
- package/dist/node_modules/fast-uri/test/compatibility.test.js +0 -131
- package/dist/node_modules/jsonfile/CHANGELOG.md +0 -171
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
* @see [source](https://github.com/nodejs/node/blob/v20.13.1/lib/dgram.js)
|
|
27
27
|
*/
|
|
28
28
|
declare module "dgram" {
|
|
29
|
+
import { NonSharedBuffer } from "node:buffer";
|
|
29
30
|
import { AddressInfo } from "node:net";
|
|
30
31
|
import * as dns from "node:dns";
|
|
31
32
|
import { Abortable, EventEmitter } from "node:events";
|
|
@@ -82,8 +83,8 @@ declare module "dgram" {
|
|
|
82
83
|
* @param options Available options are:
|
|
83
84
|
* @param callback Attached as a listener for `'message'` events. Optional.
|
|
84
85
|
*/
|
|
85
|
-
function createSocket(type: SocketType, callback?: (msg:
|
|
86
|
-
function createSocket(options: SocketOptions, callback?: (msg:
|
|
86
|
+
function createSocket(type: SocketType, callback?: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): Socket;
|
|
87
|
+
function createSocket(options: SocketOptions, callback?: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): Socket;
|
|
87
88
|
/**
|
|
88
89
|
* Encapsulates the datagram functionality.
|
|
89
90
|
*
|
|
@@ -352,22 +353,22 @@ declare module "dgram" {
|
|
|
352
353
|
* @param callback Called when the message has been sent.
|
|
353
354
|
*/
|
|
354
355
|
send(
|
|
355
|
-
msg: string |
|
|
356
|
+
msg: string | NodeJS.ArrayBufferView | readonly any[],
|
|
356
357
|
port?: number,
|
|
357
358
|
address?: string,
|
|
358
359
|
callback?: (error: Error | null, bytes: number) => void,
|
|
359
360
|
): void;
|
|
360
361
|
send(
|
|
361
|
-
msg: string |
|
|
362
|
+
msg: string | NodeJS.ArrayBufferView | readonly any[],
|
|
362
363
|
port?: number,
|
|
363
364
|
callback?: (error: Error | null, bytes: number) => void,
|
|
364
365
|
): void;
|
|
365
366
|
send(
|
|
366
|
-
msg: string |
|
|
367
|
+
msg: string | NodeJS.ArrayBufferView | readonly any[],
|
|
367
368
|
callback?: (error: Error | null, bytes: number) => void,
|
|
368
369
|
): void;
|
|
369
370
|
send(
|
|
370
|
-
msg: string |
|
|
371
|
+
msg: string | NodeJS.ArrayBufferView,
|
|
371
372
|
offset: number,
|
|
372
373
|
length: number,
|
|
373
374
|
port?: number,
|
|
@@ -375,14 +376,14 @@ declare module "dgram" {
|
|
|
375
376
|
callback?: (error: Error | null, bytes: number) => void,
|
|
376
377
|
): void;
|
|
377
378
|
send(
|
|
378
|
-
msg: string |
|
|
379
|
+
msg: string | NodeJS.ArrayBufferView,
|
|
379
380
|
offset: number,
|
|
380
381
|
length: number,
|
|
381
382
|
port?: number,
|
|
382
383
|
callback?: (error: Error | null, bytes: number) => void,
|
|
383
384
|
): void;
|
|
384
385
|
send(
|
|
385
|
-
msg: string |
|
|
386
|
+
msg: string | NodeJS.ArrayBufferView,
|
|
386
387
|
offset: number,
|
|
387
388
|
length: number,
|
|
388
389
|
callback?: (error: Error | null, bytes: number) => void,
|
|
@@ -553,37 +554,37 @@ declare module "dgram" {
|
|
|
553
554
|
addListener(event: "connect", listener: () => void): this;
|
|
554
555
|
addListener(event: "error", listener: (err: Error) => void): this;
|
|
555
556
|
addListener(event: "listening", listener: () => void): this;
|
|
556
|
-
addListener(event: "message", listener: (msg:
|
|
557
|
+
addListener(event: "message", listener: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): this;
|
|
557
558
|
emit(event: string | symbol, ...args: any[]): boolean;
|
|
558
559
|
emit(event: "close"): boolean;
|
|
559
560
|
emit(event: "connect"): boolean;
|
|
560
561
|
emit(event: "error", err: Error): boolean;
|
|
561
562
|
emit(event: "listening"): boolean;
|
|
562
|
-
emit(event: "message", msg:
|
|
563
|
+
emit(event: "message", msg: NonSharedBuffer, rinfo: RemoteInfo): boolean;
|
|
563
564
|
on(event: string, listener: (...args: any[]) => void): this;
|
|
564
565
|
on(event: "close", listener: () => void): this;
|
|
565
566
|
on(event: "connect", listener: () => void): this;
|
|
566
567
|
on(event: "error", listener: (err: Error) => void): this;
|
|
567
568
|
on(event: "listening", listener: () => void): this;
|
|
568
|
-
on(event: "message", listener: (msg:
|
|
569
|
+
on(event: "message", listener: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): this;
|
|
569
570
|
once(event: string, listener: (...args: any[]) => void): this;
|
|
570
571
|
once(event: "close", listener: () => void): this;
|
|
571
572
|
once(event: "connect", listener: () => void): this;
|
|
572
573
|
once(event: "error", listener: (err: Error) => void): this;
|
|
573
574
|
once(event: "listening", listener: () => void): this;
|
|
574
|
-
once(event: "message", listener: (msg:
|
|
575
|
+
once(event: "message", listener: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): this;
|
|
575
576
|
prependListener(event: string, listener: (...args: any[]) => void): this;
|
|
576
577
|
prependListener(event: "close", listener: () => void): this;
|
|
577
578
|
prependListener(event: "connect", listener: () => void): this;
|
|
578
579
|
prependListener(event: "error", listener: (err: Error) => void): this;
|
|
579
580
|
prependListener(event: "listening", listener: () => void): this;
|
|
580
|
-
prependListener(event: "message", listener: (msg:
|
|
581
|
+
prependListener(event: "message", listener: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): this;
|
|
581
582
|
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
|
|
582
583
|
prependOnceListener(event: "close", listener: () => void): this;
|
|
583
584
|
prependOnceListener(event: "connect", listener: () => void): this;
|
|
584
585
|
prependOnceListener(event: "error", listener: (err: Error) => void): this;
|
|
585
586
|
prependOnceListener(event: "listening", listener: () => void): this;
|
|
586
|
-
prependOnceListener(event: "message", listener: (msg:
|
|
587
|
+
prependOnceListener(event: "message", listener: (msg: NonSharedBuffer, rinfo: RemoteInfo) => void): this;
|
|
587
588
|
/**
|
|
588
589
|
* Calls `socket.close()` and returns a promise that fulfills when the socket has closed.
|
|
589
590
|
* @since v20.5.0
|
|
@@ -259,7 +259,7 @@ declare module "diagnostics_channel" {
|
|
|
259
259
|
* @param store The store to unbind from the channel.
|
|
260
260
|
* @return `true` if the store was found, `false` otherwise.
|
|
261
261
|
*/
|
|
262
|
-
unbindStore(store:
|
|
262
|
+
unbindStore(store: AsyncLocalStorage<StoreType>): boolean;
|
|
263
263
|
/**
|
|
264
264
|
* Applies the given data to any AsyncLocalStorage instances bound to the channel
|
|
265
265
|
* for the duration of the given function, then publishes to the channel within
|
|
@@ -297,7 +297,12 @@ declare module "diagnostics_channel" {
|
|
|
297
297
|
* @param thisArg The receiver to be used for the function call.
|
|
298
298
|
* @param args Optional arguments to pass to the function.
|
|
299
299
|
*/
|
|
300
|
-
runStores(
|
|
300
|
+
runStores<ThisArg = any, Args extends any[] = any[], Result = any>(
|
|
301
|
+
context: ContextType,
|
|
302
|
+
fn: (this: ThisArg, ...args: Args) => Result,
|
|
303
|
+
thisArg?: ThisArg,
|
|
304
|
+
...args: Args
|
|
305
|
+
): Result;
|
|
301
306
|
}
|
|
302
307
|
interface TracingChannelSubscribers<ContextType extends object> {
|
|
303
308
|
start: (message: ContextType) => void;
|
|
@@ -441,12 +446,12 @@ declare module "diagnostics_channel" {
|
|
|
441
446
|
* @param args Optional arguments to pass to the function
|
|
442
447
|
* @return The return value of the given function
|
|
443
448
|
*/
|
|
444
|
-
traceSync<ThisArg = any, Args extends any[] = any[]>(
|
|
445
|
-
fn: (this: ThisArg, ...args: Args) =>
|
|
449
|
+
traceSync<ThisArg = any, Args extends any[] = any[], Result = any>(
|
|
450
|
+
fn: (this: ThisArg, ...args: Args) => Result,
|
|
446
451
|
context?: ContextType,
|
|
447
452
|
thisArg?: ThisArg,
|
|
448
453
|
...args: Args
|
|
449
|
-
):
|
|
454
|
+
): Result;
|
|
450
455
|
/**
|
|
451
456
|
* Trace a promise-returning function call. This will always produce a `start event` and `end event` around the synchronous portion of the
|
|
452
457
|
* function execution, and will produce an `asyncStart event` and `asyncEnd event` when a promise continuation is reached. It may also
|
|
@@ -476,12 +481,12 @@ declare module "diagnostics_channel" {
|
|
|
476
481
|
* @param args Optional arguments to pass to the function
|
|
477
482
|
* @return Chained from promise returned by the given function
|
|
478
483
|
*/
|
|
479
|
-
tracePromise<ThisArg = any, Args extends any[] = any[]>(
|
|
480
|
-
fn: (this: ThisArg, ...args: Args) => Promise<
|
|
484
|
+
tracePromise<ThisArg = any, Args extends any[] = any[], Result = any>(
|
|
485
|
+
fn: (this: ThisArg, ...args: Args) => Promise<Result>,
|
|
481
486
|
context?: ContextType,
|
|
482
487
|
thisArg?: ThisArg,
|
|
483
488
|
...args: Args
|
|
484
|
-
):
|
|
489
|
+
): Promise<Result>;
|
|
485
490
|
/**
|
|
486
491
|
* Trace a callback-receiving function call. This will always produce a `start event` and `end event` around the synchronous portion of the
|
|
487
492
|
* function execution, and will produce a `asyncStart event` and `asyncEnd event` around the callback execution. It may also produce an `error event` if the given function throws an error or
|
|
@@ -540,13 +545,32 @@ declare module "diagnostics_channel" {
|
|
|
540
545
|
* @param args Optional arguments to pass to the function
|
|
541
546
|
* @return The return value of the given function
|
|
542
547
|
*/
|
|
543
|
-
traceCallback<
|
|
544
|
-
fn:
|
|
545
|
-
position
|
|
546
|
-
context
|
|
547
|
-
thisArg
|
|
548
|
-
...args:
|
|
549
|
-
):
|
|
548
|
+
traceCallback<ThisArg = any, Args extends any[] = any[], Result = any>(
|
|
549
|
+
fn: (this: ThisArg, ...args: Args) => Result,
|
|
550
|
+
position?: number,
|
|
551
|
+
context?: ContextType,
|
|
552
|
+
thisArg?: ThisArg,
|
|
553
|
+
...args: Args
|
|
554
|
+
): Result;
|
|
555
|
+
/**
|
|
556
|
+
* `true` if any of the individual channels has a subscriber, `false` if not.
|
|
557
|
+
*
|
|
558
|
+
* This is a helper method available on a {@link TracingChannel} instance to check
|
|
559
|
+
* if any of the [TracingChannel Channels](https://nodejs.org/api/diagnostics_channel.html#tracingchannel-channels) have subscribers.
|
|
560
|
+
* A `true` is returned if any of them have at least one subscriber, a `false` is returned otherwise.
|
|
561
|
+
*
|
|
562
|
+
* ```js
|
|
563
|
+
* const diagnostics_channel = require('node:diagnostics_channel');
|
|
564
|
+
*
|
|
565
|
+
* const channels = diagnostics_channel.tracingChannel('my-channel');
|
|
566
|
+
*
|
|
567
|
+
* if (channels.hasSubscribers) {
|
|
568
|
+
* // Do something
|
|
569
|
+
* }
|
|
570
|
+
* ```
|
|
571
|
+
* @since v22.0.0, v20.13.0
|
|
572
|
+
*/
|
|
573
|
+
readonly hasSubscribers: boolean;
|
|
550
574
|
}
|
|
551
575
|
}
|
|
552
576
|
declare module "node:diagnostics_channel" {
|
|
@@ -126,22 +126,24 @@ declare module "dns/promises" {
|
|
|
126
126
|
* @param [rrtype='A'] Resource record type.
|
|
127
127
|
*/
|
|
128
128
|
function resolve(hostname: string): Promise<string[]>;
|
|
129
|
-
function resolve(hostname: string, rrtype: "A"): Promise<string[]>;
|
|
130
|
-
function resolve(hostname: string, rrtype: "AAAA"): Promise<string[]>;
|
|
129
|
+
function resolve(hostname: string, rrtype: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
|
|
131
130
|
function resolve(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
|
|
132
131
|
function resolve(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
|
|
133
|
-
function resolve(hostname: string, rrtype: "CNAME"): Promise<string[]>;
|
|
134
132
|
function resolve(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
|
|
135
133
|
function resolve(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
|
|
136
|
-
function resolve(hostname: string, rrtype: "NS"): Promise<string[]>;
|
|
137
|
-
function resolve(hostname: string, rrtype: "PTR"): Promise<string[]>;
|
|
138
134
|
function resolve(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
|
|
139
135
|
function resolve(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
|
|
140
136
|
function resolve(hostname: string, rrtype: "TXT"): Promise<string[][]>;
|
|
141
|
-
function resolve(
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
137
|
+
function resolve(hostname: string, rrtype: string): Promise<
|
|
138
|
+
| string[]
|
|
139
|
+
| CaaRecord[]
|
|
140
|
+
| MxRecord[]
|
|
141
|
+
| NaptrRecord[]
|
|
142
|
+
| SoaRecord
|
|
143
|
+
| SrvRecord[]
|
|
144
|
+
| string[][]
|
|
145
|
+
| AnyRecord[]
|
|
146
|
+
>;
|
|
145
147
|
/**
|
|
146
148
|
* Uses the DNS protocol to resolve IPv4 addresses (`A` records) for the `hostname`. On success, the `Promise` is resolved with an array of IPv4
|
|
147
149
|
* addresses (e.g. `['74.125.79.104', '74.125.79.105', '74.125.79.106']`).
|
|
@@ -249,6 +249,9 @@ declare module "dns" {
|
|
|
249
249
|
contactemail?: string | undefined;
|
|
250
250
|
contactphone?: string | undefined;
|
|
251
251
|
}
|
|
252
|
+
export interface AnyCaaRecord extends CaaRecord {
|
|
253
|
+
type: "CAA";
|
|
254
|
+
}
|
|
252
255
|
export interface MxRecord {
|
|
253
256
|
priority: number;
|
|
254
257
|
exchange: string;
|
|
@@ -307,6 +310,7 @@ declare module "dns" {
|
|
|
307
310
|
export type AnyRecord =
|
|
308
311
|
| AnyARecord
|
|
309
312
|
| AnyAaaaRecord
|
|
313
|
+
| AnyCaaRecord
|
|
310
314
|
| AnyCnameRecord
|
|
311
315
|
| AnyMxRecord
|
|
312
316
|
| AnyNaptrRecord
|
|
@@ -334,12 +338,7 @@ declare module "dns" {
|
|
|
334
338
|
): void;
|
|
335
339
|
export function resolve(
|
|
336
340
|
hostname: string,
|
|
337
|
-
rrtype: "A",
|
|
338
|
-
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
|
|
339
|
-
): void;
|
|
340
|
-
export function resolve(
|
|
341
|
-
hostname: string,
|
|
342
|
-
rrtype: "AAAA",
|
|
341
|
+
rrtype: "A" | "AAAA" | "CNAME" | "NS" | "PTR",
|
|
343
342
|
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
|
|
344
343
|
): void;
|
|
345
344
|
export function resolve(
|
|
@@ -349,8 +348,8 @@ declare module "dns" {
|
|
|
349
348
|
): void;
|
|
350
349
|
export function resolve(
|
|
351
350
|
hostname: string,
|
|
352
|
-
rrtype: "
|
|
353
|
-
callback: (err: NodeJS.ErrnoException | null,
|
|
351
|
+
rrtype: "CAA",
|
|
352
|
+
callback: (err: NodeJS.ErrnoException | null, address: CaaRecord[]) => void,
|
|
354
353
|
): void;
|
|
355
354
|
export function resolve(
|
|
356
355
|
hostname: string,
|
|
@@ -362,16 +361,6 @@ declare module "dns" {
|
|
|
362
361
|
rrtype: "NAPTR",
|
|
363
362
|
callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void,
|
|
364
363
|
): void;
|
|
365
|
-
export function resolve(
|
|
366
|
-
hostname: string,
|
|
367
|
-
rrtype: "NS",
|
|
368
|
-
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
|
|
369
|
-
): void;
|
|
370
|
-
export function resolve(
|
|
371
|
-
hostname: string,
|
|
372
|
-
rrtype: "PTR",
|
|
373
|
-
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
|
|
374
|
-
): void;
|
|
375
364
|
export function resolve(
|
|
376
365
|
hostname: string,
|
|
377
366
|
rrtype: "SOA",
|
|
@@ -392,12 +381,21 @@ declare module "dns" {
|
|
|
392
381
|
rrtype: string,
|
|
393
382
|
callback: (
|
|
394
383
|
err: NodeJS.ErrnoException | null,
|
|
395
|
-
addresses:
|
|
384
|
+
addresses:
|
|
385
|
+
| string[]
|
|
386
|
+
| CaaRecord[]
|
|
387
|
+
| MxRecord[]
|
|
388
|
+
| NaptrRecord[]
|
|
389
|
+
| SoaRecord
|
|
390
|
+
| SrvRecord[]
|
|
391
|
+
| string[][]
|
|
392
|
+
| AnyRecord[],
|
|
396
393
|
) => void,
|
|
397
394
|
): void;
|
|
398
395
|
export namespace resolve {
|
|
399
396
|
function __promisify__(hostname: string, rrtype?: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
|
|
400
397
|
function __promisify__(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
|
|
398
|
+
function __promisify__(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
|
|
401
399
|
function __promisify__(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
|
|
402
400
|
function __promisify__(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
|
|
403
401
|
function __promisify__(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
|
|
@@ -406,7 +404,16 @@ declare module "dns" {
|
|
|
406
404
|
function __promisify__(
|
|
407
405
|
hostname: string,
|
|
408
406
|
rrtype: string,
|
|
409
|
-
): Promise<
|
|
407
|
+
): Promise<
|
|
408
|
+
| string[]
|
|
409
|
+
| CaaRecord[]
|
|
410
|
+
| MxRecord[]
|
|
411
|
+
| NaptrRecord[]
|
|
412
|
+
| SoaRecord
|
|
413
|
+
| SrvRecord[]
|
|
414
|
+
| string[][]
|
|
415
|
+
| AnyRecord[]
|
|
416
|
+
>;
|
|
410
417
|
}
|
|
411
418
|
/**
|
|
412
419
|
* Uses the DNS protocol to resolve a IPv4 addresses (`A` records) for the `hostname`. The `addresses` argument passed to the `callback` function
|
|
@@ -776,7 +783,7 @@ declare module "dns" {
|
|
|
776
783
|
* The number of tries the resolver will try contacting each name server before giving up.
|
|
777
784
|
* @default 4
|
|
778
785
|
*/
|
|
779
|
-
tries?: number;
|
|
786
|
+
tries?: number | undefined;
|
|
780
787
|
}
|
|
781
788
|
/**
|
|
782
789
|
* An independent resolver for DNS requests.
|
|
@@ -36,39 +36,6 @@
|
|
|
36
36
|
*/
|
|
37
37
|
declare module "events" {
|
|
38
38
|
import { AsyncResource, AsyncResourceOptions } from "node:async_hooks";
|
|
39
|
-
// NOTE: This class is in the docs but is **not actually exported** by Node.
|
|
40
|
-
// If https://github.com/nodejs/node/issues/39903 gets resolved and Node
|
|
41
|
-
// actually starts exporting the class, uncomment below.
|
|
42
|
-
// import { EventListener, EventListenerObject } from '__dom-events';
|
|
43
|
-
// /** The NodeEventTarget is a Node.js-specific extension to EventTarget that emulates a subset of the EventEmitter API. */
|
|
44
|
-
// interface NodeEventTarget extends EventTarget {
|
|
45
|
-
// /**
|
|
46
|
-
// * Node.js-specific extension to the `EventTarget` class that emulates the equivalent `EventEmitter` API.
|
|
47
|
-
// * The only difference between `addListener()` and `addEventListener()` is that addListener() will return a reference to the EventTarget.
|
|
48
|
-
// */
|
|
49
|
-
// addListener(type: string, listener: EventListener | EventListenerObject, options?: { once: boolean }): this;
|
|
50
|
-
// /** Node.js-specific extension to the `EventTarget` class that returns an array of event `type` names for which event listeners are registered. */
|
|
51
|
-
// eventNames(): string[];
|
|
52
|
-
// /** Node.js-specific extension to the `EventTarget` class that returns the number of event listeners registered for the `type`. */
|
|
53
|
-
// listenerCount(type: string): number;
|
|
54
|
-
// /** Node.js-specific alias for `eventTarget.removeListener()`. */
|
|
55
|
-
// off(type: string, listener: EventListener | EventListenerObject): this;
|
|
56
|
-
// /** Node.js-specific alias for `eventTarget.addListener()`. */
|
|
57
|
-
// on(type: string, listener: EventListener | EventListenerObject, options?: { once: boolean }): this;
|
|
58
|
-
// /** Node.js-specific extension to the `EventTarget` class that adds a `once` listener for the given event `type`. This is equivalent to calling `on` with the `once` option set to `true`. */
|
|
59
|
-
// once(type: string, listener: EventListener | EventListenerObject): this;
|
|
60
|
-
// /**
|
|
61
|
-
// * Node.js-specific extension to the `EventTarget` class.
|
|
62
|
-
// * If `type` is specified, removes all registered listeners for `type`,
|
|
63
|
-
// * otherwise removes all registered listeners.
|
|
64
|
-
// */
|
|
65
|
-
// removeAllListeners(type: string): this;
|
|
66
|
-
// /**
|
|
67
|
-
// * Node.js-specific extension to the `EventTarget` class that removes the listener for the given `type`.
|
|
68
|
-
// * The only difference between `removeListener()` and `removeEventListener()` is that `removeListener()` will return a reference to the `EventTarget`.
|
|
69
|
-
// */
|
|
70
|
-
// removeListener(type: string, listener: EventListener | EventListenerObject): this;
|
|
71
|
-
// }
|
|
72
39
|
interface EventEmitterOptions {
|
|
73
40
|
/**
|
|
74
41
|
* Enables automatic capturing of promise rejection.
|
|
@@ -518,7 +485,7 @@ declare module "events" {
|
|
|
518
485
|
* directly rather than as a child class.
|
|
519
486
|
* @default new.target.name if instantiated as a child class.
|
|
520
487
|
*/
|
|
521
|
-
name?: string;
|
|
488
|
+
name?: string | undefined;
|
|
522
489
|
}
|
|
523
490
|
|
|
524
491
|
/**
|
|
@@ -585,6 +552,85 @@ declare module "events" {
|
|
|
585
552
|
*/
|
|
586
553
|
readonly asyncResource: EventEmitterReferencingAsyncResource;
|
|
587
554
|
}
|
|
555
|
+
/**
|
|
556
|
+
* The `NodeEventTarget` is a Node.js-specific extension to `EventTarget`
|
|
557
|
+
* that emulates a subset of the `EventEmitter` API.
|
|
558
|
+
* @since v14.5.0
|
|
559
|
+
*/
|
|
560
|
+
export interface NodeEventTarget extends EventTarget {
|
|
561
|
+
/**
|
|
562
|
+
* Node.js-specific extension to the `EventTarget` class that emulates the
|
|
563
|
+
* equivalent `EventEmitter` API. The only difference between `addListener()` and
|
|
564
|
+
* `addEventListener()` is that `addListener()` will return a reference to the
|
|
565
|
+
* `EventTarget`.
|
|
566
|
+
* @since v14.5.0
|
|
567
|
+
*/
|
|
568
|
+
addListener(type: string, listener: (arg: any) => void): this;
|
|
569
|
+
/**
|
|
570
|
+
* Node.js-specific extension to the `EventTarget` class that dispatches the
|
|
571
|
+
* `arg` to the list of handlers for `type`.
|
|
572
|
+
* @since v15.2.0
|
|
573
|
+
* @returns `true` if event listeners registered for the `type` exist,
|
|
574
|
+
* otherwise `false`.
|
|
575
|
+
*/
|
|
576
|
+
emit(type: string, arg: any): boolean;
|
|
577
|
+
/**
|
|
578
|
+
* Node.js-specific extension to the `EventTarget` class that returns an array
|
|
579
|
+
* of event `type` names for which event listeners are registered.
|
|
580
|
+
* @since 14.5.0
|
|
581
|
+
*/
|
|
582
|
+
eventNames(): string[];
|
|
583
|
+
/**
|
|
584
|
+
* Node.js-specific extension to the `EventTarget` class that returns the number
|
|
585
|
+
* of event listeners registered for the `type`.
|
|
586
|
+
* @since v14.5.0
|
|
587
|
+
*/
|
|
588
|
+
listenerCount(type: string): number;
|
|
589
|
+
/**
|
|
590
|
+
* Node.js-specific extension to the `EventTarget` class that sets the number
|
|
591
|
+
* of max event listeners as `n`.
|
|
592
|
+
* @since v14.5.0
|
|
593
|
+
*/
|
|
594
|
+
setMaxListeners(n: number): void;
|
|
595
|
+
/**
|
|
596
|
+
* Node.js-specific extension to the `EventTarget` class that returns the number
|
|
597
|
+
* of max event listeners.
|
|
598
|
+
* @since v14.5.0
|
|
599
|
+
*/
|
|
600
|
+
getMaxListeners(): number;
|
|
601
|
+
/**
|
|
602
|
+
* Node.js-specific alias for `eventTarget.removeEventListener()`.
|
|
603
|
+
* @since v14.5.0
|
|
604
|
+
*/
|
|
605
|
+
off(type: string, listener: (arg: any) => void, options?: EventListenerOptions): this;
|
|
606
|
+
/**
|
|
607
|
+
* Node.js-specific alias for `eventTarget.addEventListener()`.
|
|
608
|
+
* @since v14.5.0
|
|
609
|
+
*/
|
|
610
|
+
on(type: string, listener: (arg: any) => void): this;
|
|
611
|
+
/**
|
|
612
|
+
* Node.js-specific extension to the `EventTarget` class that adds a `once`
|
|
613
|
+
* listener for the given event `type`. This is equivalent to calling `on`
|
|
614
|
+
* with the `once` option set to `true`.
|
|
615
|
+
* @since v14.5.0
|
|
616
|
+
*/
|
|
617
|
+
once(type: string, listener: (arg: any) => void): this;
|
|
618
|
+
/**
|
|
619
|
+
* Node.js-specific extension to the `EventTarget` class. If `type` is specified,
|
|
620
|
+
* removes all registered listeners for `type`, otherwise removes all registered
|
|
621
|
+
* listeners.
|
|
622
|
+
* @since v14.5.0
|
|
623
|
+
*/
|
|
624
|
+
removeAllListeners(type?: string): this;
|
|
625
|
+
/**
|
|
626
|
+
* Node.js-specific extension to the `EventTarget` class that removes the
|
|
627
|
+
* `listener` for the given `type`. The only difference between `removeListener()`
|
|
628
|
+
* and `removeEventListener()` is that `removeListener()` will return a reference
|
|
629
|
+
* to the `EventTarget`.
|
|
630
|
+
* @since v14.5.0
|
|
631
|
+
*/
|
|
632
|
+
removeListener(type: string, listener: (arg: any) => void, options?: EventListenerOptions): this;
|
|
633
|
+
}
|
|
588
634
|
}
|
|
589
635
|
global {
|
|
590
636
|
namespace NodeJS {
|
|
@@ -768,7 +814,7 @@ declare module "events" {
|
|
|
768
814
|
setMaxListeners(n: number): this;
|
|
769
815
|
/**
|
|
770
816
|
* Returns the current max listener value for the `EventEmitter` which is either
|
|
771
|
-
* set by `emitter.setMaxListeners(n)` or defaults to {@link defaultMaxListeners}.
|
|
817
|
+
* set by `emitter.setMaxListeners(n)` or defaults to {@link EventEmitter.defaultMaxListeners}.
|
|
772
818
|
* @since v1.0.0
|
|
773
819
|
*/
|
|
774
820
|
getMaxListeners(): number;
|