Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/node

Package Overview
Dependencies
Maintainers
1
Versions
1959
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/node - npm Package Compare versions

Comparing version 18.17.18 to 18.17.19

72

node v18.17/assert.d.ts

@@ -6,3 +6,3 @@ /**

*/
declare module 'assert' {
declare module "assert" {
/**

@@ -24,3 +24,3 @@ * An alias of {@link ok}.

generatedMessage: boolean;
code: 'ERR_ASSERTION';
code: "ERR_ASSERTION";
constructor(options?: {

@@ -191,3 +191,3 @@ /** If provided, the error message is set to this value. */

}
type AssertPredicate = RegExp | (new () => object) | ((thrown: unknown) => boolean) | object | Error;
type AssertPredicate = RegExp | (new() => object) | ((thrown: unknown) => boolean) | object | Error;
/**

@@ -224,3 +224,3 @@ * Throws an `AssertionError` with the provided error message or a default

// tslint:disable-next-line:ban-types
stackStartFn?: Function
stackStartFn?: Function,
): never;

@@ -853,3 +853,7 @@ /**

function rejects(block: (() => Promise<unknown>) | Promise<unknown>, message?: string | Error): Promise<void>;
function rejects(block: (() => Promise<unknown>) | Promise<unknown>, error: AssertPredicate, message?: string | Error): Promise<void>;
function rejects(
block: (() => Promise<unknown>) | Promise<unknown>,
error: AssertPredicate,
message?: string | Error,
): Promise<void>;
/**

@@ -897,4 +901,11 @@ * Awaits the `asyncFn` promise or, if `asyncFn` is a function, immediately

*/
function doesNotReject(block: (() => Promise<unknown>) | Promise<unknown>, message?: string | Error): Promise<void>;
function doesNotReject(block: (() => Promise<unknown>) | Promise<unknown>, error: AssertPredicate, message?: string | Error): Promise<void>;
function doesNotReject(
block: (() => Promise<unknown>) | Promise<unknown>,
message?: string | Error,
): Promise<void>;
function doesNotReject(
block: (() => Promise<unknown>) | Promise<unknown>,
error: AssertPredicate,
message?: string | Error,
): Promise<void>;
/**

@@ -946,23 +957,36 @@ * Expects the `string` input to match the regular expression.

function doesNotMatch(value: string, regExp: RegExp, message?: string | Error): void;
const strict: Omit<typeof assert, 'equal' | 'notEqual' | 'deepEqual' | 'notDeepEqual' | 'ok' | 'strictEqual' | 'deepStrictEqual' | 'ifError' | 'strict'> & {
(value: unknown, message?: string | Error): asserts value;
equal: typeof strictEqual;
notEqual: typeof notStrictEqual;
deepEqual: typeof deepStrictEqual;
notDeepEqual: typeof notDeepStrictEqual;
// Mapped types and assertion functions are incompatible?
// TS2775: Assertions require every name in the call target
// to be declared with an explicit type annotation.
ok: typeof ok;
strictEqual: typeof strictEqual;
deepStrictEqual: typeof deepStrictEqual;
ifError: typeof ifError;
strict: typeof strict;
};
const strict:
& Omit<
typeof assert,
| "equal"
| "notEqual"
| "deepEqual"
| "notDeepEqual"
| "ok"
| "strictEqual"
| "deepStrictEqual"
| "ifError"
| "strict"
>
& {
(value: unknown, message?: string | Error): asserts value;
equal: typeof strictEqual;
notEqual: typeof notStrictEqual;
deepEqual: typeof deepStrictEqual;
notDeepEqual: typeof notDeepStrictEqual;
// Mapped types and assertion functions are incompatible?
// TS2775: Assertions require every name in the call target
// to be declared with an explicit type annotation.
ok: typeof ok;
strictEqual: typeof strictEqual;
deepStrictEqual: typeof deepStrictEqual;
ifError: typeof ifError;
strict: typeof strict;
};
}
export = assert;
}
declare module 'node:assert' {
import assert = require('assert');
declare module "node:assert" {
import assert = require("assert");
export = assert;
}

@@ -1,8 +0,8 @@

declare module 'assert/strict' {
import { strict } from 'node:assert';
declare module "assert/strict" {
import { strict } from "node:assert";
export = strict;
}
declare module 'node:assert/strict' {
import { strict } from 'node:assert';
declare module "node:assert/strict" {
import { strict } from "node:assert";
export = strict;
}

@@ -11,3 +11,3 @@ /**

*/
declare module 'async_hooks' {
declare module "async_hooks" {
/**

@@ -277,3 +277,3 @@ * ```js

type?: string,
thisArg?: ThisArg
thisArg?: ThisArg,
): Func & {

@@ -291,3 +291,3 @@ asyncResource: AsyncResource;

bind<Func extends (...args: any[]) => any>(
fn: Func
fn: Func,
): Func & {

@@ -306,3 +306,7 @@ asyncResource: AsyncResource;

*/
runInAsyncScope<This, Result>(fn: (this: This, ...args: any[]) => Result, thisArg?: This, ...args: any[]): Result;
runInAsyncScope<This, Result>(
fn: (this: This, ...args: any[]) => Result,
thisArg?: This,
...args: any[]
): Result;
/**

@@ -321,3 +325,2 @@ * Call all `destroy` hooks. This should only ever be called once. An error will

/**
*
* @return The same `triggerAsyncId` that is passed to the `AsyncResource` constructor.

@@ -522,4 +525,4 @@ */

}
declare module 'node:async_hooks' {
export * from 'async_hooks';
declare module "node:async_hooks" {
export * from "async_hooks";
}

@@ -55,7 +55,7 @@ /**

*/
declare module 'cluster' {
import * as child from 'node:child_process';
import EventEmitter = require('node:events');
import * as net from 'node:net';
type SerializationType = 'json' | 'advanced';
declare module "cluster" {
import * as child from "node:child_process";
import EventEmitter = require("node:events");
import * as net from "node:net";
type SerializationType = "json" | "advanced";
export interface ClusterSettings {

@@ -77,3 +77,3 @@ execArgv?: string[] | undefined; // default: process.execArgv

port: number;
addressType: number | 'udp4' | 'udp6'; // 4, 6, -1, "udp4", "udp6"
addressType: number | "udp4" | "udp6"; // 4, 6, -1, "udp4", "udp6"
}

@@ -130,4 +130,13 @@ /**

send(message: child.Serializable, callback?: (error: Error | null) => void): boolean;
send(message: child.Serializable, sendHandle: child.SendHandle, callback?: (error: Error | null) => void): boolean;
send(message: child.Serializable, sendHandle: child.SendHandle, options?: child.MessageOptions, callback?: (error: Error | null) => void): boolean;
send(
message: child.Serializable,
sendHandle: child.SendHandle,
callback?: (error: Error | null) => void,
): boolean;
send(
message: child.Serializable,
sendHandle: child.SendHandle,
options?: child.MessageOptions,
callback?: (error: Error | null) => void,
): boolean;
/**

@@ -289,43 +298,43 @@ * This function will kill the worker. In the primary worker, it does this by

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'disconnect', listener: () => void): this;
addListener(event: 'error', listener: (error: Error) => void): this;
addListener(event: 'exit', listener: (code: number, signal: string) => void): this;
addListener(event: 'listening', listener: (address: Address) => void): this;
addListener(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: 'online', listener: () => void): this;
addListener(event: "disconnect", listener: () => void): this;
addListener(event: "error", listener: (error: Error) => void): this;
addListener(event: "exit", listener: (code: number, signal: string) => void): this;
addListener(event: "listening", listener: (address: Address) => void): this;
addListener(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: "online", listener: () => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'disconnect'): boolean;
emit(event: 'error', error: Error): boolean;
emit(event: 'exit', code: number, signal: string): boolean;
emit(event: 'listening', address: Address): boolean;
emit(event: 'message', message: any, handle: net.Socket | net.Server): boolean;
emit(event: 'online'): boolean;
emit(event: "disconnect"): boolean;
emit(event: "error", error: Error): boolean;
emit(event: "exit", code: number, signal: string): boolean;
emit(event: "listening", address: Address): boolean;
emit(event: "message", message: any, handle: net.Socket | net.Server): boolean;
emit(event: "online"): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'disconnect', listener: () => void): this;
on(event: 'error', listener: (error: Error) => void): this;
on(event: 'exit', listener: (code: number, signal: string) => void): this;
on(event: 'listening', listener: (address: Address) => void): this;
on(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: 'online', listener: () => void): this;
on(event: "disconnect", listener: () => void): this;
on(event: "error", listener: (error: Error) => void): this;
on(event: "exit", listener: (code: number, signal: string) => void): this;
on(event: "listening", listener: (address: Address) => void): this;
on(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: "online", listener: () => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'disconnect', listener: () => void): this;
once(event: 'error', listener: (error: Error) => void): this;
once(event: 'exit', listener: (code: number, signal: string) => void): this;
once(event: 'listening', listener: (address: Address) => void): this;
once(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: 'online', listener: () => void): this;
once(event: "disconnect", listener: () => void): this;
once(event: "error", listener: (error: Error) => void): this;
once(event: "exit", listener: (code: number, signal: string) => void): this;
once(event: "listening", listener: (address: Address) => void): this;
once(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: "online", listener: () => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'disconnect', listener: () => void): this;
prependListener(event: 'error', listener: (error: Error) => void): this;
prependListener(event: 'exit', listener: (code: number, signal: string) => void): this;
prependListener(event: 'listening', listener: (address: Address) => void): this;
prependListener(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependListener(event: 'online', listener: () => void): this;
prependListener(event: "disconnect", listener: () => void): this;
prependListener(event: "error", listener: (error: Error) => void): this;
prependListener(event: "exit", listener: (code: number, signal: string) => void): this;
prependListener(event: "listening", listener: (address: Address) => void): this;
prependListener(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependListener(event: "online", listener: () => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'disconnect', listener: () => void): this;
prependOnceListener(event: 'error', listener: (error: Error) => void): this;
prependOnceListener(event: 'exit', listener: (code: number, signal: string) => void): this;
prependOnceListener(event: 'listening', listener: (address: Address) => void): this;
prependOnceListener(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependOnceListener(event: 'online', listener: () => void): this;
prependOnceListener(event: "disconnect", listener: () => void): this;
prependOnceListener(event: "error", listener: (error: Error) => void): this;
prependOnceListener(event: "exit", listener: (code: number, signal: string) => void): this;
prependOnceListener(event: "listening", listener: (address: Address) => void): this;
prependOnceListener(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependOnceListener(event: "online", listener: () => void): this;
}

@@ -362,51 +371,60 @@ export interface Cluster extends EventEmitter {

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'disconnect', listener: (worker: Worker) => void): this;
addListener(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
addListener(event: 'fork', listener: (worker: Worker) => void): this;
addListener(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
addListener(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: 'online', listener: (worker: Worker) => void): this;
addListener(event: 'setup', listener: (settings: ClusterSettings) => void): this;
addListener(event: "disconnect", listener: (worker: Worker) => void): this;
addListener(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
addListener(event: "fork", listener: (worker: Worker) => void): this;
addListener(event: "listening", listener: (worker: Worker, address: Address) => void): this;
addListener(
event: "message",
listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void,
): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: "online", listener: (worker: Worker) => void): this;
addListener(event: "setup", listener: (settings: ClusterSettings) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'disconnect', worker: Worker): boolean;
emit(event: 'exit', worker: Worker, code: number, signal: string): boolean;
emit(event: 'fork', worker: Worker): boolean;
emit(event: 'listening', worker: Worker, address: Address): boolean;
emit(event: 'message', worker: Worker, message: any, handle: net.Socket | net.Server): boolean;
emit(event: 'online', worker: Worker): boolean;
emit(event: 'setup', settings: ClusterSettings): boolean;
emit(event: "disconnect", worker: Worker): boolean;
emit(event: "exit", worker: Worker, code: number, signal: string): boolean;
emit(event: "fork", worker: Worker): boolean;
emit(event: "listening", worker: Worker, address: Address): boolean;
emit(event: "message", worker: Worker, message: any, handle: net.Socket | net.Server): boolean;
emit(event: "online", worker: Worker): boolean;
emit(event: "setup", settings: ClusterSettings): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'disconnect', listener: (worker: Worker) => void): this;
on(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
on(event: 'fork', listener: (worker: Worker) => void): this;
on(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
on(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: 'online', listener: (worker: Worker) => void): this;
on(event: 'setup', listener: (settings: ClusterSettings) => void): this;
on(event: "disconnect", listener: (worker: Worker) => void): this;
on(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
on(event: "fork", listener: (worker: Worker) => void): this;
on(event: "listening", listener: (worker: Worker, address: Address) => void): this;
on(event: "message", listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: "online", listener: (worker: Worker) => void): this;
on(event: "setup", listener: (settings: ClusterSettings) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'disconnect', listener: (worker: Worker) => void): this;
once(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
once(event: 'fork', listener: (worker: Worker) => void): this;
once(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
once(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: 'online', listener: (worker: Worker) => void): this;
once(event: 'setup', listener: (settings: ClusterSettings) => void): this;
once(event: "disconnect", listener: (worker: Worker) => void): this;
once(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
once(event: "fork", listener: (worker: Worker) => void): this;
once(event: "listening", listener: (worker: Worker, address: Address) => void): this;
once(event: "message", listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: "online", listener: (worker: Worker) => void): this;
once(event: "setup", listener: (settings: ClusterSettings) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'disconnect', listener: (worker: Worker) => void): this;
prependListener(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
prependListener(event: 'fork', listener: (worker: Worker) => void): this;
prependListener(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
prependListener(event: "disconnect", listener: (worker: Worker) => void): this;
prependListener(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
prependListener(event: "fork", listener: (worker: Worker) => void): this;
prependListener(event: "listening", listener: (worker: Worker, address: Address) => void): this;
// the handle is a net.Socket or net.Server object, or undefined.
prependListener(event: 'message', listener: (worker: Worker, message: any, handle?: net.Socket | net.Server) => void): this;
prependListener(event: 'online', listener: (worker: Worker) => void): this;
prependListener(event: 'setup', listener: (settings: ClusterSettings) => void): this;
prependListener(
event: "message",
listener: (worker: Worker, message: any, handle?: net.Socket | net.Server) => void,
): this;
prependListener(event: "online", listener: (worker: Worker) => void): this;
prependListener(event: "setup", listener: (settings: ClusterSettings) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'disconnect', listener: (worker: Worker) => void): this;
prependOnceListener(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
prependOnceListener(event: 'fork', listener: (worker: Worker) => void): this;
prependOnceListener(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
prependOnceListener(event: "disconnect", listener: (worker: Worker) => void): this;
prependOnceListener(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
prependOnceListener(event: "fork", listener: (worker: Worker) => void): this;
prependOnceListener(event: "listening", listener: (worker: Worker, address: Address) => void): this;
// the handle is a net.Socket or net.Server object, or undefined.
prependOnceListener(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this;
prependOnceListener(event: 'online', listener: (worker: Worker) => void): this;
prependOnceListener(event: 'setup', listener: (settings: ClusterSettings) => void): this;
prependOnceListener(
event: "message",
listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void,
): this;
prependOnceListener(event: "online", listener: (worker: Worker) => void): this;
prependOnceListener(event: "setup", listener: (settings: ClusterSettings) => void): this;
}

@@ -416,5 +434,5 @@ const cluster: Cluster;

}
declare module 'node:cluster' {
export * from 'cluster';
export { default as default } from 'cluster';
declare module "node:cluster" {
export * from "cluster";
export { default as default } from "cluster";
}

@@ -58,8 +58,8 @@ /**

*/
declare module 'console' {
import console = require('node:console');
declare module "console" {
import console = require("node:console");
export = console;
}
declare module 'node:console' {
import { InspectOptions } from 'node:util';
declare module "node:console" {
import { InspectOptions } from "node:util";
global {

@@ -396,3 +396,3 @@ // This needs to be global to avoid TS2403 in case lib.dom.d.ts is present in the same build

ignoreErrors?: boolean | undefined;
colorMode?: boolean | 'auto' | undefined;
colorMode?: boolean | "auto" | undefined;
inspectOptions?: InspectOptions | undefined;

@@ -407,4 +407,4 @@ /**

prototype: Console;
new (stdout: NodeJS.WritableStream, stderr?: NodeJS.WritableStream, ignoreErrors?: boolean): Console;
new (options: ConsoleConstructorOptions): Console;
new(stdout: NodeJS.WritableStream, stderr?: NodeJS.WritableStream, ignoreErrors?: boolean): Console;
new(options: ConsoleConstructorOptions): Console;
}

@@ -411,0 +411,0 @@ }

/** @deprecated since v6.3.0 - use constants property exposed by the relevant module instead. */
declare module 'constants' {
import { constants as osConstants, SignalConstants } from 'node:os';
import { constants as cryptoConstants } from 'node:crypto';
import { constants as fsConstants } from 'node:fs';
declare module "constants" {
import { constants as osConstants, SignalConstants } from "node:os";
import { constants as cryptoConstants } from "node:crypto";
import { constants as fsConstants } from "node:fs";
const exp: typeof osConstants.errno &
typeof osConstants.priority &
SignalConstants &
typeof cryptoConstants &
typeof fsConstants;
const exp:
& typeof osConstants.errno
& typeof osConstants.priority
& SignalConstants
& typeof cryptoConstants
& typeof fsConstants;
export = exp;
}
declare module 'node:constants' {
import constants = require('constants');
declare module "node:constants" {
import constants = require("constants");
export = constants;
}

@@ -28,9 +28,9 @@ /**

*/
declare module 'dgram' {
import { AddressInfo } from 'node:net';
import * as dns from 'node:dns';
import { EventEmitter, Abortable } from 'node:events';
declare module "dgram" {
import { AddressInfo } from "node:net";
import * as dns from "node:dns";
import { Abortable, EventEmitter } from "node:events";
interface RemoteInfo {
address: string;
family: 'IPv4' | 'IPv6';
family: "IPv4" | "IPv6";
port: number;

@@ -45,3 +45,3 @@ size: number;

}
type SocketType = 'udp4' | 'udp6';
type SocketType = "udp4" | "udp6";
interface SocketOptions extends Abortable {

@@ -56,3 +56,9 @@ type: SocketType;

sendBufferSize?: number | undefined;
lookup?: ((hostname: string, options: dns.LookupOneOptions, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void) => void) | undefined;
lookup?:
| ((
hostname: string,
options: dns.LookupOneOptions,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
) => void)
| undefined;
}

@@ -341,8 +347,38 @@ /**

*/
send(msg: string | Uint8Array | ReadonlyArray<any>, port?: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array | ReadonlyArray<any>, port?: number, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array | ReadonlyArray<any>, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array, offset: number, length: number, port?: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array, offset: number, length: number, port?: number, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array, offset: number, length: number, callback?: (error: Error | null, bytes: number) => void): void;
send(
msg: string | Uint8Array | ReadonlyArray<any>,
port?: number,
address?: string,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array | ReadonlyArray<any>,
port?: number,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array | ReadonlyArray<any>,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array,
offset: number,
length: number,
port?: number,
address?: string,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array,
offset: number,
length: number,
port?: number,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array,
offset: number,
length: number,
callback?: (error: Error | null, bytes: number) => void,
): void;
/**

@@ -510,41 +546,41 @@ * Sets or clears the `SO_BROADCAST` socket option. When set to `true`, UDP

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'connect', listener: () => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'listening', listener: () => void): this;
addListener(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "connect", listener: () => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "listening", listener: () => void): this;
addListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'connect'): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'listening'): boolean;
emit(event: 'message', msg: Buffer, rinfo: RemoteInfo): boolean;
emit(event: "close"): boolean;
emit(event: "connect"): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "listening"): boolean;
emit(event: "message", msg: Buffer, rinfo: RemoteInfo): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'connect', listener: () => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'listening', listener: () => void): this;
on(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
on(event: "close", listener: () => void): this;
on(event: "connect", listener: () => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "listening", listener: () => void): this;
on(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'connect', listener: () => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'listening', listener: () => void): this;
once(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
once(event: "close", listener: () => void): this;
once(event: "connect", listener: () => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "listening", listener: () => void): this;
once(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'connect', listener: () => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'listening', listener: () => void): this;
prependListener(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "connect", listener: () => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "listening", listener: () => void): this;
prependListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'connect', listener: () => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'listening', listener: () => void): this;
prependOnceListener(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "connect", listener: () => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "listening", listener: () => void): this;
prependOnceListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
}
}
declare module 'node:dgram' {
export * from 'dgram';
declare module "node:dgram" {
export * from "dgram";
}

@@ -25,3 +25,3 @@ /**

*/
declare module 'diagnostics_channel' {
declare module "diagnostics_channel" {
/**

@@ -191,4 +191,4 @@ * Check if there are active subscribers to the named channel. This is helpful if

}
declare module 'node:diagnostics_channel' {
export * from 'diagnostics_channel';
declare module "node:diagnostics_channel" {
export * from "diagnostics_channel";
}

@@ -47,4 +47,4 @@ /**

*/
declare module 'dns' {
import * as dnsPromises from 'node:dns/promises';
declare module "dns" {
import * as dnsPromises from "node:dns/promises";
// Supported getaddrinfo flags.

@@ -119,7 +119,26 @@ export const ADDRCONFIG: number;

*/
export function lookup(hostname: string, family: number, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void): void;
export function lookup(hostname: string, options: LookupOneOptions, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void): void;
export function lookup(hostname: string, options: LookupAllOptions, callback: (err: NodeJS.ErrnoException | null, addresses: LookupAddress[]) => void): void;
export function lookup(hostname: string, options: LookupOptions, callback: (err: NodeJS.ErrnoException | null, address: string | LookupAddress[], family: number) => void): void;
export function lookup(hostname: string, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void): void;
export function lookup(
hostname: string,
family: number,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
): void;
export function lookup(
hostname: string,
options: LookupOneOptions,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
): void;
export function lookup(
hostname: string,
options: LookupAllOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: LookupAddress[]) => void,
): void;
export function lookup(
hostname: string,
options: LookupOptions,
callback: (err: NodeJS.ErrnoException | null, address: string | LookupAddress[], family: number) => void,
): void;
export function lookup(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
): void;
export namespace lookup {

@@ -150,7 +169,11 @@ function __promisify__(hostname: string, options: LookupAllOptions): Promise<LookupAddress[]>;

*/
export function lookupService(address: string, port: number, callback: (err: NodeJS.ErrnoException | null, hostname: string, service: string) => void): void;
export function lookupService(
address: string,
port: number,
callback: (err: NodeJS.ErrnoException | null, hostname: string, service: string) => void,
): void;
export namespace lookupService {
function __promisify__(
address: string,
port: number
port: number,
): Promise<{

@@ -174,6 +197,6 @@ hostname: string;

export interface AnyARecord extends RecordWithTtl {
type: 'A';
type: "A";
}
export interface AnyAaaaRecord extends RecordWithTtl {
type: 'AAAA';
type: "AAAA";
}

@@ -193,3 +216,3 @@ export interface CaaRecord {

export interface AnyMxRecord extends MxRecord {
type: 'MX';
type: "MX";
}

@@ -205,3 +228,3 @@ export interface NaptrRecord {

export interface AnyNaptrRecord extends NaptrRecord {
type: 'NAPTR';
type: "NAPTR";
}

@@ -218,3 +241,3 @@ export interface SoaRecord {

export interface AnySoaRecord extends SoaRecord {
type: 'SOA';
type: "SOA";
}

@@ -228,21 +251,31 @@ export interface SrvRecord {

export interface AnySrvRecord extends SrvRecord {
type: 'SRV';
type: "SRV";
}
export interface AnyTxtRecord {
type: 'TXT';
type: "TXT";
entries: string[];
}
export interface AnyNsRecord {
type: 'NS';
type: "NS";
value: string;
}
export interface AnyPtrRecord {
type: 'PTR';
type: "PTR";
value: string;
}
export interface AnyCnameRecord {
type: 'CNAME';
type: "CNAME";
value: string;
}
export type AnyRecord = AnyARecord | AnyAaaaRecord | AnyCnameRecord | AnyMxRecord | AnyNaptrRecord | AnyNsRecord | AnyPtrRecord | AnySoaRecord | AnySrvRecord | AnyTxtRecord;
export type AnyRecord =
| AnyARecord
| AnyAaaaRecord
| AnyCnameRecord
| AnyMxRecord
| AnyNaptrRecord
| AnyNsRecord
| AnyPtrRecord
| AnySoaRecord
| AnySrvRecord
| AnyTxtRecord;
/**

@@ -260,28 +293,81 @@ * Uses the DNS protocol to resolve a host name (e.g. `'nodejs.org'`) into an array

*/
export function resolve(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'A', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'AAAA', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'ANY', callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'CNAME', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'MX', callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'NAPTR', callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'NS', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'PTR', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'SOA', callback: (err: NodeJS.ErrnoException | null, addresses: SoaRecord) => void): void;
export function resolve(hostname: string, rrtype: 'SRV', callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'TXT', callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void): void;
export function resolve(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "A",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "AAAA",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "ANY",
callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "CNAME",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "MX",
callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "NAPTR",
callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "NS",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "PTR",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "SOA",
callback: (err: NodeJS.ErrnoException | null, addresses: SoaRecord) => void,
): void;
export function resolve(
hostname: string,
rrtype: "SRV",
callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "TXT",
callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void,
): void;
export function resolve(
hostname: string,
rrtype: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]) => void
callback: (
err: NodeJS.ErrnoException | null,
addresses: string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[],
) => void,
): void;
export namespace resolve {
function __promisify__(hostname: string, rrtype?: 'A' | 'AAAA' | 'CNAME' | 'NS' | 'PTR'): Promise<string[]>;
function __promisify__(hostname: string, rrtype: 'ANY'): Promise<AnyRecord[]>;
function __promisify__(hostname: string, rrtype: 'MX'): Promise<MxRecord[]>;
function __promisify__(hostname: string, rrtype: 'NAPTR'): Promise<NaptrRecord[]>;
function __promisify__(hostname: string, rrtype: 'SOA'): Promise<SoaRecord>;
function __promisify__(hostname: string, rrtype: 'SRV'): Promise<SrvRecord[]>;
function __promisify__(hostname: string, rrtype: 'TXT'): Promise<string[][]>;
function __promisify__(hostname: string, rrtype: string): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
function __promisify__(hostname: string, rrtype?: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
function __promisify__(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
function __promisify__(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
function __promisify__(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
function __promisify__(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
function __promisify__(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
function __promisify__(hostname: string, rrtype: "TXT"): Promise<string[][]>;
function __promisify__(
hostname: string,
rrtype: string,
): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
}

@@ -294,5 +380,16 @@ /**

*/
export function resolve4(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve4(hostname: string, options: ResolveWithTtlOptions, callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void): void;
export function resolve4(hostname: string, options: ResolveOptions, callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void): void;
export function resolve4(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve4(
hostname: string,
options: ResolveWithTtlOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void,
): void;
export function resolve4(
hostname: string,
options: ResolveOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void,
): void;
export namespace resolve4 {

@@ -309,5 +406,16 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolve6(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve6(hostname: string, options: ResolveWithTtlOptions, callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void): void;
export function resolve6(hostname: string, options: ResolveOptions, callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void): void;
export function resolve6(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve6(
hostname: string,
options: ResolveWithTtlOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void,
): void;
export function resolve6(
hostname: string,
options: ResolveOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void,
): void;
export namespace resolve6 {

@@ -323,3 +431,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolveCname(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolveCname(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export namespace resolveCname {

@@ -334,3 +445,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolveCaa(hostname: string, callback: (err: NodeJS.ErrnoException | null, records: CaaRecord[]) => void): void;
export function resolveCaa(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, records: CaaRecord[]) => void,
): void;
export namespace resolveCaa {

@@ -344,3 +458,6 @@ function __promisify__(hostname: string): Promise<CaaRecord[]>;

*/
export function resolveMx(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void): void;
export function resolveMx(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void,
): void;
export namespace resolveMx {

@@ -372,3 +489,6 @@ function __promisify__(hostname: string): Promise<MxRecord[]>;

*/
export function resolveNaptr(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void): void;
export function resolveNaptr(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void,
): void;
export namespace resolveNaptr {

@@ -382,3 +502,6 @@ function __promisify__(hostname: string): Promise<NaptrRecord[]>;

*/
export function resolveNs(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolveNs(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export namespace resolveNs {

@@ -392,3 +515,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolvePtr(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolvePtr(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export namespace resolvePtr {

@@ -423,3 +549,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolveSoa(hostname: string, callback: (err: NodeJS.ErrnoException | null, address: SoaRecord) => void): void;
export function resolveSoa(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, address: SoaRecord) => void,
): void;
export namespace resolveSoa {

@@ -447,3 +576,6 @@ function __promisify__(hostname: string): Promise<SoaRecord>;

*/
export function resolveSrv(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void): void;
export function resolveSrv(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void,
): void;
export namespace resolveSrv {

@@ -459,3 +591,6 @@ function __promisify__(hostname: string): Promise<SrvRecord[]>;

*/
export function resolveTxt(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void): void;
export function resolveTxt(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void,
): void;
export namespace resolveTxt {

@@ -494,3 +629,6 @@ function __promisify__(hostname: string): Promise<string[][]>;

*/
export function resolveAny(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void): void;
export function resolveAny(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void,
): void;
export namespace resolveAny {

@@ -507,3 +645,6 @@ function __promisify__(hostname: string): Promise<AnyRecord[]>;

*/
export function reverse(ip: string, callback: (err: NodeJS.ErrnoException | null, hostnames: string[]) => void): void;
export function reverse(
ip: string,
callback: (err: NodeJS.ErrnoException | null, hostnames: string[]) => void,
): void;
/**

@@ -516,3 +657,3 @@ * Get the default value for `verbatim` in {@link lookup} and `dnsPromises.lookup()`. The value could be:

*/
export function getDefaultResultOrder(): 'ipv4first' | 'verbatim';
export function getDefaultResultOrder(): "ipv4first" | "verbatim";
/**

@@ -575,3 +716,3 @@ * Sets the IP address and port of servers to be used when performing DNS

*/
export function setDefaultResultOrder(order: 'ipv4first' | 'verbatim'): void;
export function setDefaultResultOrder(order: "ipv4first" | "verbatim"): void;
// Error codes

@@ -690,4 +831,4 @@ export const NODATA: string;

}
declare module 'node:dns' {
export * from 'dns';
declare module "node:dns" {
export * from "dns";
}

@@ -7,19 +7,19 @@ /**

*/
declare module 'dns/promises' {
declare module "dns/promises" {
import {
AnyRecord,
CaaRecord,
LookupAddress,
LookupAllOptions,
LookupOneOptions,
LookupAllOptions,
LookupOptions,
AnyRecord,
CaaRecord,
MxRecord,
NaptrRecord,
SoaRecord,
SrvRecord,
ResolveWithTtlOptions,
RecordWithTtl,
ResolveOptions,
ResolverOptions,
} from 'node:dns';
ResolveWithTtlOptions,
SoaRecord,
SrvRecord,
} from "node:dns";
/**

@@ -110,3 +110,3 @@ * Returns an array of IP address strings, formatted according to [RFC 5952](https://tools.ietf.org/html/rfc5952#section-6),

address: string,
port: number
port: number,
): Promise<{

@@ -130,15 +130,18 @@ hostname: string;

function resolve(hostname: string): Promise<string[]>;
function resolve(hostname: string, rrtype: 'A'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'AAAA'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'ANY'): Promise<AnyRecord[]>;
function resolve(hostname: string, rrtype: 'CAA'): Promise<CaaRecord[]>;
function resolve(hostname: string, rrtype: 'CNAME'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'MX'): Promise<MxRecord[]>;
function resolve(hostname: string, rrtype: 'NAPTR'): Promise<NaptrRecord[]>;
function resolve(hostname: string, rrtype: 'NS'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'PTR'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'SOA'): Promise<SoaRecord>;
function resolve(hostname: string, rrtype: 'SRV'): Promise<SrvRecord[]>;
function resolve(hostname: string, rrtype: 'TXT'): Promise<string[][]>;
function resolve(hostname: string, rrtype: string): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
function resolve(hostname: string, rrtype: "A"): Promise<string[]>;
function resolve(hostname: string, rrtype: "AAAA"): Promise<string[]>;
function resolve(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
function resolve(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
function resolve(hostname: string, rrtype: "CNAME"): Promise<string[]>;
function resolve(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
function resolve(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
function resolve(hostname: string, rrtype: "NS"): Promise<string[]>;
function resolve(hostname: string, rrtype: "PTR"): Promise<string[]>;
function resolve(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
function resolve(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
function resolve(hostname: string, rrtype: "TXT"): Promise<string[][]>;
function resolve(
hostname: string,
rrtype: string,
): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
/**

@@ -349,3 +352,3 @@ * Uses the DNS protocol to resolve IPv4 addresses (`A` records) for the`hostname`. On success, the `Promise` is resolved with an array of IPv4

*/
function setDefaultResultOrder(order: 'ipv4first' | 'verbatim'): void;
function setDefaultResultOrder(order: "ipv4first" | "verbatim"): void;
class Resolver {

@@ -372,4 +375,4 @@ constructor(options?: ResolverOptions);

}
declare module 'node:dns/promises' {
export * from 'dns/promises';
declare module "node:dns/promises" {
export * from "dns/promises";
}

@@ -11,68 +11,66 @@ export {}; // Don't export anything!

// the copy below in a Node environment.
type __Event = typeof globalThis extends { onmessage: any, Event: any }
? {}
: {
/** This is not used in Node.js and is provided purely for completeness. */
readonly bubbles: boolean;
/** Alias for event.stopPropagation(). This is not used in Node.js and is provided purely for completeness. */
cancelBubble: () => void;
/** True if the event was created with the cancelable option */
readonly cancelable: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly composed: boolean;
/** Returns an array containing the current EventTarget as the only entry or empty if the event is not being dispatched. This is not used in Node.js and is provided purely for completeness. */
composedPath(): [EventTarget?]
/** Alias for event.target. */
readonly currentTarget: EventTarget | null;
/** Is true if cancelable is true and event.preventDefault() has been called. */
readonly defaultPrevented: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly eventPhase: 0 | 2;
/** The `AbortSignal` "abort" event is emitted with `isTrusted` set to `true`. The value is `false` in all other cases. */
readonly isTrusted: boolean;
/** Sets the `defaultPrevented` property to `true` if `cancelable` is `true`. */
preventDefault(): void;
/** This is not used in Node.js and is provided purely for completeness. */
returnValue: boolean;
/** Alias for event.target. */
readonly srcElement: EventTarget | null;
/** Stops the invocation of event listeners after the current one completes. */
stopImmediatePropagation(): void;
/** This is not used in Node.js and is provided purely for completeness. */
stopPropagation(): void;
/** The `EventTarget` dispatching the event */
readonly target: EventTarget | null;
/** The millisecond timestamp when the Event object was created. */
readonly timeStamp: number;
/** Returns the type of event, e.g. "click", "hashchange", or "submit". */
readonly type: string;
};
type __Event = typeof globalThis extends { onmessage: any; Event: any } ? {}
: {
/** This is not used in Node.js and is provided purely for completeness. */
readonly bubbles: boolean;
/** Alias for event.stopPropagation(). This is not used in Node.js and is provided purely for completeness. */
cancelBubble: () => void;
/** True if the event was created with the cancelable option */
readonly cancelable: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly composed: boolean;
/** Returns an array containing the current EventTarget as the only entry or empty if the event is not being dispatched. This is not used in Node.js and is provided purely for completeness. */
composedPath(): [EventTarget?];
/** Alias for event.target. */
readonly currentTarget: EventTarget | null;
/** Is true if cancelable is true and event.preventDefault() has been called. */
readonly defaultPrevented: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly eventPhase: 0 | 2;
/** The `AbortSignal` "abort" event is emitted with `isTrusted` set to `true`. The value is `false` in all other cases. */
readonly isTrusted: boolean;
/** Sets the `defaultPrevented` property to `true` if `cancelable` is `true`. */
preventDefault(): void;
/** This is not used in Node.js and is provided purely for completeness. */
returnValue: boolean;
/** Alias for event.target. */
readonly srcElement: EventTarget | null;
/** Stops the invocation of event listeners after the current one completes. */
stopImmediatePropagation(): void;
/** This is not used in Node.js and is provided purely for completeness. */
stopPropagation(): void;
/** The `EventTarget` dispatching the event */
readonly target: EventTarget | null;
/** The millisecond timestamp when the Event object was created. */
readonly timeStamp: number;
/** Returns the type of event, e.g. "click", "hashchange", or "submit". */
readonly type: string;
};
// See comment above explaining conditional type
type __EventTarget = typeof globalThis extends { onmessage: any, EventTarget: any }
? {}
: {
/**
* Adds a new handler for the `type` event. Any given `listener` is added only once per `type` and per `capture` option value.
*
* If the `once` option is true, the `listener` is removed after the next time a `type` event is dispatched.
*
* The `capture` option is not used by Node.js in any functional way other than tracking registered event listeners per the `EventTarget` specification.
* Specifically, the `capture` option is used as part of the key when registering a `listener`.
* Any individual `listener` may be added once with `capture = false`, and once with `capture = true`.
*/
addEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: AddEventListenerOptions | boolean,
): void;
/** Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise. */
dispatchEvent(event: Event): boolean;
/** Removes the event listener in target's event listener list with the same type, callback, and options. */
removeEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: EventListenerOptions | boolean,
): void;
};
type __EventTarget = typeof globalThis extends { onmessage: any; EventTarget: any } ? {}
: {
/**
* Adds a new handler for the `type` event. Any given `listener` is added only once per `type` and per `capture` option value.
*
* If the `once` option is true, the `listener` is removed after the next time a `type` event is dispatched.
*
* The `capture` option is not used by Node.js in any functional way other than tracking registered event listeners per the `EventTarget` specification.
* Specifically, the `capture` option is used as part of the key when registering a `listener`.
* Any individual `listener` may be added once with `capture = false`, and once with `capture = true`.
*/
addEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: AddEventListenerOptions | boolean,
): void;
/** Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise. */
dispatchEvent(event: Event): boolean;
/** Removes the event listener in target's event listener list with the same type, callback, and options. */
removeEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: EventListenerOptions | boolean,
): void;
};

@@ -105,11 +103,10 @@ interface EventInit {

import {} from 'events'; // Make this an ambient declaration
import {} from "events"; // Make this an ambient declaration
declare global {
/** An event which takes place in the DOM. */
interface Event extends __Event {}
var Event: typeof globalThis extends { onmessage: any, Event: infer T }
? T
var Event: typeof globalThis extends { onmessage: any; Event: infer T } ? T
: {
prototype: __Event;
new (type: string, eventInitDict?: EventInit): __Event;
new(type: string, eventInitDict?: EventInit): __Event;
};

@@ -122,8 +119,7 @@

interface EventTarget extends __EventTarget {}
var EventTarget: typeof globalThis extends { onmessage: any, EventTarget: infer T }
? T
var EventTarget: typeof globalThis extends { onmessage: any; EventTarget: infer T } ? T
: {
prototype: __EventTarget;
new (): __EventTarget;
new(): __EventTarget;
};
}

@@ -17,4 +17,4 @@ /**

*/
declare module 'domain' {
import EventEmitter = require('node:events');
declare module "domain" {
import EventEmitter = require("node:events");
/**

@@ -169,4 +169,4 @@ * The `Domain` class encapsulates the functionality of routing errors and

}
declare module 'node:domain' {
export * from 'domain';
declare module "node:domain" {
export * from "domain";
}

@@ -37,3 +37,3 @@ /**

*/
declare module 'events' {
declare module "events" {
// NOTE: This class is in the docs but is **not actually exported** by Node.

@@ -91,3 +91,3 @@ // If https://github.com/nodejs/node/issues/39903 gets resolved and Node

once: boolean;
}
},
): any;

@@ -196,3 +196,7 @@ }

*/
static once(emitter: _NodeEventTarget, eventName: string | symbol, options?: StaticEventEmitterOptions): Promise<any[]>;
static once(
emitter: _NodeEventTarget,
eventName: string | symbol,
options?: StaticEventEmitterOptions,
): Promise<any[]>;
static once(emitter: _DOMEventTarget, eventName: string, options?: StaticEventEmitterOptions): Promise<any[]>;

@@ -257,3 +261,7 @@ /**

*/
static on(emitter: NodeJS.EventEmitter, eventName: string, options?: StaticEventEmitterOptions): AsyncIterableIterator<any>;
static on(
emitter: NodeJS.EventEmitter,
eventName: string,
options?: StaticEventEmitterOptions,
): AsyncIterableIterator<any>;
/**

@@ -369,3 +377,3 @@ * A class method that returns the number of listeners for the given `eventName`registered on the given `emitter`.

}
import internal = require('node:events');
import internal = require("node:events");
namespace EventEmitter {

@@ -713,5 +721,5 @@ // Should just be `export { EventEmitter }`, but that doesn't work in TypeScript 3.4

}
declare module 'node:events' {
import events = require('events');
declare module "node:events" {
import events = require("events");
export = events;
}

@@ -11,6 +11,6 @@ /**

*/
declare module 'fs/promises' {
import { Abortable } from 'node:events';
import { Stream } from 'node:stream';
import { ReadableStream } from 'node:stream/web';
declare module "fs/promises" {
import { Abortable } from "node:events";
import { Stream } from "node:stream";
import { ReadableStream } from "node:stream/web";
import {

@@ -34,4 +34,4 @@ BigIntStats,

RmOptions,
StatFsOptions,
StatOptions,
StatFsOptions,
Stats,

@@ -44,4 +44,4 @@ StatsFs,

WriteVResult,
} from 'node:fs';
import { Interface as ReadlineInterface } from 'node:readline';
} from "node:fs";
import { Interface as ReadlineInterface } from "node:readline";

@@ -95,3 +95,3 @@ interface FileChangeInfo<T extends string | Buffer> {

*/
type?: 'bytes' | undefined;
type?: "bytes" | undefined;
}

@@ -113,3 +113,6 @@ // TODO: Add `EventEmitter` close

*/
appendFile(data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null): Promise<void>;
appendFile(
data: string | Uint8Array,
options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null,
): Promise<void>;
/**

@@ -231,3 +234,8 @@ * Changes the ownership of the file. A wrapper for [`chown(2)`](http://man7.org/linux/man-pages/man2/chown.2.html).

*/
read<T extends NodeJS.ArrayBufferView>(buffer: T, offset?: number | null, length?: number | null, position?: number | null): Promise<FileReadResult<T>>;
read<T extends NodeJS.ArrayBufferView>(
buffer: T,
offset?: number | null,
length?: number | null,
position?: number | null,
): Promise<FileReadResult<T>>;
read<T extends NodeJS.ArrayBufferView = Buffer>(options?: FileReadOptions<T>): Promise<FileReadResult<T>>;

@@ -275,3 +283,3 @@ /**

flag?: OpenMode | undefined;
} | null
} | null,
): Promise<Buffer>;

@@ -287,6 +295,6 @@ /**

| {
encoding: BufferEncoding;
flag?: OpenMode | undefined;
}
| BufferEncoding
encoding: BufferEncoding;
flag?: OpenMode | undefined;
}
| BufferEncoding,
): Promise<string>;

@@ -302,6 +310,6 @@ /**

| (ObjectEncodingOptions & {
flag?: OpenMode | undefined;
})
flag?: OpenMode | undefined;
})
| BufferEncoding
| null
| null,
): Promise<string | Buffer>;

@@ -332,3 +340,3 @@ /**

bigint?: false | undefined;
}
},
): Promise<Stats>;

@@ -338,3 +346,3 @@ stat(

bigint: true;
}
},
): Promise<BigIntStats>;

@@ -394,3 +402,6 @@ stat(opts?: StatOptions): Promise<Stats | BigIntStats>;

*/
writeFile(data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode & Abortable) | BufferEncoding | null): Promise<void>;
writeFile(
data: string | Uint8Array,
options?: (ObjectEncodingOptions & FlagAndOpenMode & Abortable) | BufferEncoding | null,
): Promise<void>;
/**

@@ -418,3 +429,3 @@ * Write `buffer` to the file.

length?: number | null,
position?: number | null
position?: number | null,
): Promise<{

@@ -427,3 +438,3 @@ bytesWritten: number;

position?: number | null,
encoding?: BufferEncoding | null
encoding?: BufferEncoding | null,
): Promise<{

@@ -605,3 +616,3 @@ bytesWritten: number;

recursive: true;
}
},
): Promise<string | undefined>;

@@ -619,5 +630,5 @@ /**

| (MakeDirectoryOptions & {
recursive?: false | undefined;
})
| null
recursive?: false | undefined;
})
| null,
): Promise<void>;

@@ -659,7 +670,7 @@ /**

| (ObjectEncodingOptions & {
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
| BufferEncoding
| null
| null,
): Promise<string[]>;

@@ -675,7 +686,7 @@ /**

| {
encoding: 'buffer';
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
}
| 'buffer'
encoding: "buffer";
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
}
| "buffer",
): Promise<Buffer[]>;

@@ -691,7 +702,7 @@ /**

| (ObjectEncodingOptions & {
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
| BufferEncoding
| null
| null,
): Promise<string[] | Buffer[]>;

@@ -708,3 +719,3 @@ /**

recursive?: boolean | undefined;
}
},
): Promise<Dirent[]>;

@@ -757,3 +768,3 @@ /**

bigint?: false | undefined;
}
},
): Promise<Stats>;

@@ -764,3 +775,3 @@ function lstat(

bigint: true;
}
},
): Promise<BigIntStats>;

@@ -776,3 +787,3 @@ function lstat(path: PathLike, opts?: StatOptions): Promise<Stats | BigIntStats>;

bigint?: false | undefined;
}
},
): Promise<Stats>;

@@ -783,3 +794,3 @@ function stat(

bigint: true;
}
},
): Promise<BigIntStats>;

@@ -795,3 +806,3 @@ function stat(path: PathLike, opts?: StatOptions): Promise<Stats | BigIntStats>;

bigint?: false | undefined;
}
},
): Promise<StatsFs>;

@@ -802,3 +813,3 @@ function statfs(

bigint: true;
}
},
): Promise<BigIntStatsFs>;

@@ -895,3 +906,6 @@ function statfs(path: PathLike, opts?: StatFsOptions): Promise<StatsFs | BigIntStatsFs>;

*/
function realpath(path: PathLike, options?: ObjectEncodingOptions | BufferEncoding | null): Promise<string | Buffer>;
function realpath(
path: PathLike,
options?: ObjectEncodingOptions | BufferEncoding | null,
): Promise<string | Buffer>;
/**

@@ -989,10 +1003,15 @@ * Creates a unique temporary directory. A unique directory name is generated by

file: PathLike | FileHandle,
data: string | NodeJS.ArrayBufferView | Iterable<string | NodeJS.ArrayBufferView> | AsyncIterable<string | NodeJS.ArrayBufferView> | Stream,
data:
| string
| NodeJS.ArrayBufferView
| Iterable<string | NodeJS.ArrayBufferView>
| AsyncIterable<string | NodeJS.ArrayBufferView>
| Stream,
options?:
| (ObjectEncodingOptions & {
mode?: Mode | undefined;
flag?: OpenMode | undefined;
} & Abortable)
mode?: Mode | undefined;
flag?: OpenMode | undefined;
} & Abortable)
| BufferEncoding
| null
| null,
): Promise<void>;

@@ -1013,3 +1032,7 @@ /**

*/
function appendFile(path: PathLike | FileHandle, data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null): Promise<void>;
function appendFile(
path: PathLike | FileHandle,
data: string | Uint8Array,
options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null,
): Promise<void>;
/**

@@ -1061,6 +1084,6 @@ * Asynchronously reads the entire contents of a file.

| ({
encoding?: null | undefined;
flag?: OpenMode | undefined;
} & Abortable)
| null
encoding?: null | undefined;
flag?: OpenMode | undefined;
} & Abortable)
| null,
): Promise<Buffer>;

@@ -1078,6 +1101,6 @@ /**

| ({
encoding: BufferEncoding;
flag?: OpenMode | undefined;
} & Abortable)
| BufferEncoding
encoding: BufferEncoding;
flag?: OpenMode | undefined;
} & Abortable)
| BufferEncoding,
): Promise<string>;

@@ -1094,8 +1117,11 @@ /**

options?:
| (ObjectEncodingOptions &
Abortable & {
flag?: OpenMode | undefined;
})
| (
& ObjectEncodingOptions
& Abortable
& {
flag?: OpenMode | undefined;
}
)
| BufferEncoding
| null
| null,
): Promise<string | Buffer>;

@@ -1165,5 +1191,5 @@ /**

| (WatchOptions & {
encoding: 'buffer';
})
| 'buffer'
encoding: "buffer";
})
| "buffer",
): AsyncIterable<FileChangeInfo<Buffer>>;

@@ -1187,3 +1213,6 @@ /**

*/
function watch(filename: PathLike, options: WatchOptions | string): AsyncIterable<FileChangeInfo<string>> | AsyncIterable<FileChangeInfo<Buffer>>;
function watch(
filename: PathLike,
options: WatchOptions | string,
): AsyncIterable<FileChangeInfo<string>> | AsyncIterable<FileChangeInfo<Buffer>>;
/**

@@ -1203,4 +1232,4 @@ * Asynchronously copies the entire directory structure from `src` to `dest`,

}
declare module 'node:fs/promises' {
export * from 'fs/promises';
declare module "node:fs/promises" {
export * from "fs/promises";
}

@@ -23,5 +23,5 @@ // Declare "static" methods in Error

// For backwards compability
interface NodeRequire extends NodeJS.Require { }
interface RequireResolve extends NodeJS.RequireResolve { }
interface NodeModule extends NodeJS.Module { }
interface NodeRequire extends NodeJS.Require {}
interface RequireResolve extends NodeJS.RequireResolve {}
interface NodeModule extends NodeJS.Module {}

@@ -45,3 +45,3 @@ declare var process: NodeJS.Process;

//#region borrowed
// #region borrowed
// from https://github.com/microsoft/TypeScript/blob/38da7c600c83e7b31193a62495239a0fe478cb67/lib/lib.webworker.d.ts#L633 until moved to separate lib

@@ -72,4 +72,3 @@ /** A controller object that allows you to abort one or more DOM requests as and when desired. */

declare var AbortController: typeof globalThis extends {onmessage: any; AbortController: infer T}
? T
declare var AbortController: typeof globalThis extends { onmessage: any; AbortController: infer T } ? T
: {

@@ -80,4 +79,3 @@ prototype: AbortController;

declare var AbortSignal: typeof globalThis extends {onmessage: any; AbortSignal: infer T}
? T
declare var AbortSignal: typeof globalThis extends { onmessage: any; AbortSignal: infer T } ? T
: {

@@ -89,5 +87,5 @@ prototype: AbortSignal;

};
//#endregion borrowed
// #endregion borrowed
//#region ArrayLike.at()
// #region ArrayLike.at()
interface RelativeIndexable<T> {

@@ -115,3 +113,3 @@ /**

interface BigUint64Array extends RelativeIndexable<bigint> {}
//#endregion ArrayLike.at() end
// #endregion ArrayLike.at() end

@@ -125,3 +123,3 @@ /**

value: T,
transfer?: { transfer: ReadonlyArray<import('worker_threads').TransferListItem> },
transfer?: { transfer: ReadonlyArray<import("worker_threads").TransferListItem> },
): T;

@@ -223,3 +221,3 @@

isPaused(): boolean;
pipe<T extends WritableStream>(destination: T, options?: { end?: boolean | undefined; }): T;
pipe<T extends WritableStream>(destination: T, options?: { end?: boolean | undefined }): T;
unpipe(destination?: WritableStream): this;

@@ -240,3 +238,3 @@ unshift(chunk: string | Uint8Array, encoding?: BufferEncoding): void;

interface ReadWriteStream extends ReadableStream, WritableStream { }
interface ReadWriteStream extends ReadableStream, WritableStream {}

@@ -274,3 +272,3 @@ interface RefCounted {

interface RequireResolve {
(id: string, options?: { paths?: string[] | undefined; }): string;
(id: string, options?: { paths?: string[] | undefined }): string;
paths(request: string): string[] | null;

@@ -280,5 +278,5 @@ }

interface RequireExtensions extends Dict<(m: Module, filename: string) => any> {
'.js': (m: Module, filename: string) => any;
'.json': (m: Module, filename: string) => any;
'.node': (m: Module, filename: string) => any;
".js": (m: Module, filename: string) => any;
".json": (m: Module, filename: string) => any;
".node": (m: Module, filename: string) => any;
}

@@ -285,0 +283,0 @@ interface Module {

@@ -6,7 +6,7 @@ /**

*/
declare module 'https' {
import { Duplex } from 'node:stream';
import * as tls from 'node:tls';
import * as http from 'node:http';
import { URL } from 'node:url';
declare module "https" {
import { Duplex } from "node:stream";
import * as tls from "node:tls";
import * as http from "node:http";
import { URL } from "node:url";
type ServerOptions<

@@ -16,4 +16,6 @@ Request extends typeof http.IncomingMessage = typeof http.IncomingMessage,

> = tls.SecureContextOptions & tls.TlsOptions & http.ServerOptions<Request, Response>;
type RequestOptions = http.RequestOptions &
tls.SecureContextOptions & {
type RequestOptions =
& http.RequestOptions
& tls.SecureContextOptions
& {
checkServerIdentity?: typeof tls.checkServerIdentity | undefined;

@@ -63,9 +65,9 @@ rejectUnauthorized?: boolean | undefined; // Defaults to true

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
addListener(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
addListener(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
addListener(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -78,27 +80,27 @@ certificate: Buffer,

addListener(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
addListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
addListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'connection', listener: (socket: Duplex) => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'listening', listener: () => void): this;
addListener(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
addListener(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
addListener(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
addListener(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
addListener(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "connection", listener: (socket: Duplex) => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "listening", listener: () => void): this;
addListener(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
addListener(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
addListener(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
addListener(
event: 'connect',
event: "connect",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
addListener(event: 'request', listener: http.RequestListener<Request, Response>): this;
addListener(event: "request", listener: http.RequestListener<Request, Response>): this;
addListener(
event: 'upgrade',
event: "upgrade",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
emit(event: string, ...args: any[]): boolean;
emit(event: 'keylog', line: Buffer, tlsSocket: tls.TLSSocket): boolean;
emit(event: "keylog", line: Buffer, tlsSocket: tls.TLSSocket): boolean;
emit(
event: 'newSession',
event: "newSession",
sessionId: Buffer,

@@ -109,3 +111,3 @@ sessionData: Buffer,

emit(
event: 'OCSPRequest',
event: "OCSPRequest",
certificate: Buffer,

@@ -115,11 +117,11 @@ issuer: Buffer,

): boolean;
emit(event: 'resumeSession', sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void): boolean;
emit(event: 'secureConnection', tlsSocket: tls.TLSSocket): boolean;
emit(event: 'tlsClientError', err: Error, tlsSocket: tls.TLSSocket): boolean;
emit(event: 'close'): boolean;
emit(event: 'connection', socket: Duplex): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'listening'): boolean;
emit(event: "resumeSession", sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void): boolean;
emit(event: "secureConnection", tlsSocket: tls.TLSSocket): boolean;
emit(event: "tlsClientError", err: Error, tlsSocket: tls.TLSSocket): boolean;
emit(event: "close"): boolean;
emit(event: "connection", socket: Duplex): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "listening"): boolean;
emit(
event: 'checkContinue',
event: "checkContinue",
req: InstanceType<Request>,

@@ -129,22 +131,22 @@ res: InstanceType<Response> & { req: InstanceType<Request> },

emit(
event: 'checkExpectation',
event: "checkExpectation",
req: InstanceType<Request>,
res: InstanceType<Response> & { req: InstanceType<Request> },
): boolean;
emit(event: 'clientError', err: Error, socket: Duplex): boolean;
emit(event: 'connect', req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
emit(event: "clientError", err: Error, socket: Duplex): boolean;
emit(event: "connect", req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
emit(
event: 'request',
event: "request",
req: InstanceType<Request>,
res: InstanceType<Response> & { req: InstanceType<Request> },
): boolean;
emit(event: 'upgrade', req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
emit(event: "upgrade", req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
on(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
on(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
on(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -157,25 +159,25 @@ certificate: Buffer,

on(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
on(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
on(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'connection', listener: (socket: Duplex) => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'listening', listener: () => void): this;
on(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
on(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
on(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
on(event: 'connect', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
on(event: 'request', listener: http.RequestListener<Request, Response>): this;
on(event: 'upgrade', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
on(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
on(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
on(event: "close", listener: () => void): this;
on(event: "connection", listener: (socket: Duplex) => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "listening", listener: () => void): this;
on(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
on(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
on(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
on(event: "connect", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
on(event: "request", listener: http.RequestListener<Request, Response>): this;
on(event: "upgrade", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
once(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
once(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
once(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -188,25 +190,25 @@ certificate: Buffer,

once(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
once(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
once(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'connection', listener: (socket: Duplex) => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'listening', listener: () => void): this;
once(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
once(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
once(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
once(event: 'connect', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: 'request', listener: http.RequestListener<Request, Response>): this;
once(event: 'upgrade', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
once(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
once(event: "close", listener: () => void): this;
once(event: "connection", listener: (socket: Duplex) => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "listening", listener: () => void): this;
once(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
once(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
once(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
once(event: "connect", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: "request", listener: http.RequestListener<Request, Response>): this;
once(event: "upgrade", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependListener(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
prependListener(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -219,31 +221,31 @@ certificate: Buffer,

prependListener(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
prependListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'connection', listener: (socket: Duplex) => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'listening', listener: () => void): this;
prependListener(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
prependListener(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
prependListener(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
prependListener(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "connection", listener: (socket: Duplex) => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "listening", listener: () => void): this;
prependListener(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
prependListener(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
prependListener(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
prependListener(
event: 'connect',
event: "connect",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
prependListener(event: 'request', listener: http.RequestListener<Request, Response>): this;
prependListener(event: "request", listener: http.RequestListener<Request, Response>): this;
prependListener(
event: 'upgrade',
event: "upgrade",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
prependOnceListener(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -256,21 +258,21 @@ certificate: Buffer,

prependOnceListener(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
prependOnceListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'connection', listener: (socket: Duplex) => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'listening', listener: () => void): this;
prependOnceListener(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
prependOnceListener(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "connection", listener: (socket: Duplex) => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "listening", listener: () => void): this;
prependOnceListener(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
prependOnceListener(
event: 'connect',
event: "connect",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
prependOnceListener(event: 'request', listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: "request", listener: http.RequestListener<Request, Response>): this;
prependOnceListener(
event: 'upgrade',
event: "upgrade",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,

@@ -551,4 +553,4 @@ ): this;

}
declare module 'node:https' {
export * from 'https';
declare module "node:https" {
export * from "https";
}
/**
* @since v0.3.7
*/
declare module 'module' {
import { URL } from 'node:url';
import { MessagePort } from 'node:worker_threads';
declare module "module" {
import { URL } from "node:url";
import { MessagePort } from "node:worker_threads";
namespace Module {

@@ -85,3 +85,3 @@ /**

}
type ModuleFormat = 'builtin' | 'commonjs' | 'json' | 'module' | 'wasm';
type ModuleFormat = "builtin" | "commonjs" | "json" | "module" | "wasm";
type ModuleSource = string | ArrayBuffer | NodeJS.TypedArray;

@@ -144,3 +144,6 @@ interface GlobalPreloadContext {

context: ResolveHookContext,
nextResolve: (specifier: string, context?: ResolveHookContext) => ResolveFnOutput | Promise<ResolveFnOutput>
nextResolve: (
specifier: string,
context?: ResolveHookContext,
) => ResolveFnOutput | Promise<ResolveFnOutput>,
) => ResolveFnOutput | Promise<ResolveFnOutput>;

@@ -184,3 +187,3 @@ interface LoadHookContext {

context: LoadHookContext,
nextLoad: (url: string, context?: LoadHookContext) => LoadFnOutput | Promise<LoadFnOutput>
nextLoad: (url: string, context?: LoadHookContext) => LoadFnOutput | Promise<LoadFnOutput>,
) => LoadFnOutput | Promise<LoadFnOutput>;

@@ -218,5 +221,5 @@ }

}
declare module 'node:module' {
import module = require('module');
declare module "node:module" {
import module = require("module");
export = module;
}

@@ -15,7 +15,11 @@ /**

*/
declare module 'net' {
import * as stream from 'node:stream';
import { Abortable, EventEmitter } from 'node:events';
import * as dns from 'node:dns';
type LookupFunction = (hostname: string, options: dns.LookupOneOptions, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void) => void;
declare module "net" {
import * as stream from "node:stream";
import { Abortable, EventEmitter } from "node:events";
import * as dns from "node:dns";
type LookupFunction = (
hostname: string,
options: dns.LookupOneOptions,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
) => void;
interface AddressInfo {

@@ -74,3 +78,3 @@ address: string;

type SocketConnectOpts = TcpSocketConnectOpts | IpcSocketConnectOpts;
type SocketReadyState = 'opening' | 'open' | 'readOnly' | 'writeOnly' | 'closed';
type SocketReadyState = "opening" | "open" | "readOnly" | "writeOnly" | "closed";
/**

@@ -354,61 +358,76 @@ * This class is an abstraction of a TCP socket or a streaming `IPC` endpoint

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: (hadError: boolean) => void): this;
addListener(event: 'connect', listener: () => void): this;
addListener(event: 'data', listener: (data: Buffer) => void): this;
addListener(event: 'drain', listener: () => void): this;
addListener(event: 'end', listener: () => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
addListener(event: 'ready', listener: () => void): this;
addListener(event: 'timeout', listener: () => void): this;
addListener(event: "close", listener: (hadError: boolean) => void): this;
addListener(event: "connect", listener: () => void): this;
addListener(event: "data", listener: (data: Buffer) => void): this;
addListener(event: "drain", listener: () => void): this;
addListener(event: "end", listener: () => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
addListener(event: "ready", listener: () => void): this;
addListener(event: "timeout", listener: () => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close', hadError: boolean): boolean;
emit(event: 'connect'): boolean;
emit(event: 'data', data: Buffer): boolean;
emit(event: 'drain'): boolean;
emit(event: 'end'): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'lookup', err: Error, address: string, family: string | number, host: string): boolean;
emit(event: 'ready'): boolean;
emit(event: 'timeout'): boolean;
emit(event: "close", hadError: boolean): boolean;
emit(event: "connect"): boolean;
emit(event: "data", data: Buffer): boolean;
emit(event: "drain"): boolean;
emit(event: "end"): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "lookup", err: Error, address: string, family: string | number, host: string): boolean;
emit(event: "ready"): boolean;
emit(event: "timeout"): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: (hadError: boolean) => void): this;
on(event: 'connect', listener: () => void): this;
on(event: 'data', listener: (data: Buffer) => void): this;
on(event: 'drain', listener: () => void): this;
on(event: 'end', listener: () => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
on(event: 'ready', listener: () => void): this;
on(event: 'timeout', listener: () => void): this;
on(event: "close", listener: (hadError: boolean) => void): this;
on(event: "connect", listener: () => void): this;
on(event: "data", listener: (data: Buffer) => void): this;
on(event: "drain", listener: () => void): this;
on(event: "end", listener: () => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
on(event: "ready", listener: () => void): this;
on(event: "timeout", listener: () => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: (hadError: boolean) => void): this;
once(event: 'connect', listener: () => void): this;
once(event: 'data', listener: (data: Buffer) => void): this;
once(event: 'drain', listener: () => void): this;
once(event: 'end', listener: () => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
once(event: 'ready', listener: () => void): this;
once(event: 'timeout', listener: () => void): this;
once(event: "close", listener: (hadError: boolean) => void): this;
once(event: "connect", listener: () => void): this;
once(event: "data", listener: (data: Buffer) => void): this;
once(event: "drain", listener: () => void): this;
once(event: "end", listener: () => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
once(event: "ready", listener: () => void): this;
once(event: "timeout", listener: () => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: (hadError: boolean) => void): this;
prependListener(event: 'connect', listener: () => void): this;
prependListener(event: 'data', listener: (data: Buffer) => void): this;
prependListener(event: 'drain', listener: () => void): this;
prependListener(event: 'end', listener: () => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
prependListener(event: 'ready', listener: () => void): this;
prependListener(event: 'timeout', listener: () => void): this;
prependListener(event: "close", listener: (hadError: boolean) => void): this;
prependListener(event: "connect", listener: () => void): this;
prependListener(event: "data", listener: (data: Buffer) => void): this;
prependListener(event: "drain", listener: () => void): this;
prependListener(event: "end", listener: () => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
prependListener(event: "ready", listener: () => void): this;
prependListener(event: "timeout", listener: () => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: (hadError: boolean) => void): this;
prependOnceListener(event: 'connect', listener: () => void): this;
prependOnceListener(event: 'data', listener: (data: Buffer) => void): this;
prependOnceListener(event: 'drain', listener: () => void): this;
prependOnceListener(event: 'end', listener: () => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
prependOnceListener(event: 'ready', listener: () => void): this;
prependOnceListener(event: 'timeout', listener: () => void): this;
prependOnceListener(event: "close", listener: (hadError: boolean) => void): this;
prependOnceListener(event: "connect", listener: () => void): this;
prependOnceListener(event: "data", listener: (data: Buffer) => void): this;
prependOnceListener(event: "drain", listener: () => void): this;
prependOnceListener(event: "end", listener: () => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
prependOnceListener(event: "ready", listener: () => void): this;
prependOnceListener(event: "timeout", listener: () => void): this;
}

@@ -606,39 +625,39 @@ interface ListenOptions extends Abortable {

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'connection', listener: (socket: Socket) => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'listening', listener: () => void): this;
addListener(event: 'drop', listener: (data?: DropArgument) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "connection", listener: (socket: Socket) => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "listening", listener: () => void): this;
addListener(event: "drop", listener: (data?: DropArgument) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'connection', socket: Socket): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'listening'): boolean;
emit(event: 'drop', data?: DropArgument): boolean;
emit(event: "close"): boolean;
emit(event: "connection", socket: Socket): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "listening"): boolean;
emit(event: "drop", data?: DropArgument): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'connection', listener: (socket: Socket) => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'listening', listener: () => void): this;
on(event: 'drop', listener: (data?: DropArgument) => void): this;
on(event: "close", listener: () => void): this;
on(event: "connection", listener: (socket: Socket) => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "listening", listener: () => void): this;
on(event: "drop", listener: (data?: DropArgument) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'connection', listener: (socket: Socket) => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'listening', listener: () => void): this;
once(event: 'drop', listener: (data?: DropArgument) => void): this;
once(event: "close", listener: () => void): this;
once(event: "connection", listener: (socket: Socket) => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "listening", listener: () => void): this;
once(event: "drop", listener: (data?: DropArgument) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'connection', listener: (socket: Socket) => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'listening', listener: () => void): this;
prependListener(event: 'drop', listener: (data?: DropArgument) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "connection", listener: (socket: Socket) => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "listening", listener: () => void): this;
prependListener(event: "drop", listener: (data?: DropArgument) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'connection', listener: (socket: Socket) => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'listening', listener: () => void): this;
prependOnceListener(event: 'drop', listener: (data?: DropArgument) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "connection", listener: (socket: Socket) => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "listening", listener: () => void): this;
prependOnceListener(event: "drop", listener: (data?: DropArgument) => void): this;
}
type IPVersion = 'ipv4' | 'ipv6';
type IPVersion = "ipv4" | "ipv6";
/**

@@ -885,4 +904,4 @@ * The `BlockList` object can be used with some network APIs to specify rules for

}
declare module 'node:net' {
export * from 'net';
declare module "node:net" {
export * from "net";
}

@@ -10,3 +10,3 @@ /**

*/
declare module 'os' {
declare module "os" {
interface CpuInfo {

@@ -31,7 +31,7 @@ model: string;

interface NetworkInterfaceInfoIPv4 extends NetworkInterfaceBase {
family: 'IPv4';
family: "IPv4";
scopeid?: undefined;
}
interface NetworkInterfaceInfoIPv6 extends NetworkInterfaceBase {
family: 'IPv6';
family: "IPv6";
scopeid: number;

@@ -239,3 +239,3 @@ }

*/
function userInfo(options: { encoding: 'buffer' }): UserInfo<Buffer>;
function userInfo(options: { encoding: "buffer" }): UserInfo<Buffer>;
function userInfo(options?: { encoding: BufferEncoding }): UserInfo<string>;

@@ -449,3 +449,3 @@ type SignalConstants = {

*/
function endianness(): 'BE' | 'LE';
function endianness(): "BE" | "LE";
/**

@@ -475,4 +475,4 @@ * Returns the scheduling priority for the process specified by `pid`. If `pid` is

}
declare module 'node:os' {
export * from 'os';
declare module "node:os" {
export * from "os";
}
{
"name": "@types/node",
"version": "18.17.18",
"version": "18.17.19",
"description": "TypeScript definitions for Node.js",

@@ -235,4 +235,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",

"dependencies": {},
"typesPublisherContentHash": "29e3c9491858b30afaad92bf490061a13e9d6adaf3a71eaf897cffbf767f845e",
"typesPublisherContentHash": "7b1ba7dfb8193add71da2ec241d5edeb642e2742338aabe7e272e1b8b9ebbe41",
"typeScriptVersion": "4.5"
}

@@ -1,7 +0,7 @@

declare module 'path/posix' {
import path = require('path');
declare module "path/posix" {
import path = require("path");
export = path;
}
declare module 'path/win32' {
import path = require('path');
declare module "path/win32" {
import path = require("path");
export = path;

@@ -18,3 +18,3 @@ }

*/
declare module 'path' {
declare module "path" {
namespace path {

@@ -141,7 +141,7 @@ /**

*/
readonly sep: '\\' | '/';
readonly sep: "\\" | "/";
/**
* The platform-specific file delimiter. ';' or ':'.
*/
readonly delimiter: ';' | ':';
readonly delimiter: ";" | ":";
/**

@@ -182,13 +182,13 @@ * Returns an object from a path string - the opposite of format().

}
declare module 'node:path' {
import path = require('path');
declare module "node:path" {
import path = require("path");
export = path;
}
declare module 'node:path/posix' {
import path = require('path/posix');
declare module "node:path/posix" {
import path = require("path/posix");
export = path;
}
declare module 'node:path/win32' {
import path = require('path/win32');
declare module "node:path/win32" {
import path = require("path/win32");
export = path;
}

@@ -31,5 +31,5 @@ /**

*/
declare module 'perf_hooks' {
import { AsyncResource } from 'node:async_hooks';
type EntryType = 'node' | 'mark' | 'measure' | 'gc' | 'function' | 'http2' | 'http' | 'dns';
declare module "perf_hooks" {
import { AsyncResource } from "node:async_hooks";
type EntryType = "node" | "mark" | "measure" | "gc" | "function" | "http2" | "http" | "dns";
interface NodeGCPerformanceDetail {

@@ -93,6 +93,6 @@ /**

readonly duration: 0;
readonly entryType: 'mark';
readonly entryType: "mark";
}
class PerformanceMeasure extends PerformanceEntry {
readonly entryType: 'measure';
readonly entryType: "measure";
}

@@ -159,3 +159,6 @@ /**

*/
type EventLoopUtilityFunction = (util1?: EventLoopUtilization, util2?: EventLoopUtilization) => EventLoopUtilization;
type EventLoopUtilityFunction = (
util1?: EventLoopUtilization,
util2?: EventLoopUtilization,
) => EventLoopUtilization;
interface MarkOptions {

@@ -315,3 +318,2 @@ /**

*
*
* performance.clearMarks();

@@ -450,9 +452,9 @@ * performance.clearMeasures();

| {
entryTypes: ReadonlyArray<EntryType>;
buffered?: boolean | undefined;
}
entryTypes: ReadonlyArray<EntryType>;
buffered?: boolean | undefined;
}
| {
type: EntryType;
buffered?: boolean | undefined;
}
type: EntryType;
buffered?: boolean | undefined;
},
): void;

@@ -559,3 +561,3 @@ }

*/
add(other: RecordableHistogram): void;
add(other: RecordableHistogram): void;
}

@@ -614,3 +616,3 @@ /**

import { performance as _performance } from 'perf_hooks';
import { performance as _performance } from "perf_hooks";
global {

@@ -625,9 +627,8 @@ /**

performance: infer T;
}
? T
} ? T
: typeof _performance;
}
}
declare module 'node:perf_hooks' {
export * from 'perf_hooks';
declare module "node:perf_hooks" {
export * from "perf_hooks";
}

@@ -29,3 +29,3 @@ /**

*/
declare module 'punycode' {
declare module "punycode" {
/**

@@ -116,4 +116,4 @@ * The `punycode.decode()` method converts a [Punycode](https://tools.ietf.org/html/rfc3492) string of ASCII-only

}
declare module 'node:punycode' {
export * from 'punycode';
declare module "node:punycode" {
export * from "punycode";
}

@@ -14,3 +14,3 @@ /**

*/
declare module 'querystring' {
declare module "querystring" {
interface StringifyOptions {

@@ -24,3 +24,13 @@ encodeURIComponent?: ((str: string) => string) | undefined;

interface ParsedUrlQuery extends NodeJS.Dict<string | string[]> {}
interface ParsedUrlQueryInput extends NodeJS.Dict<string | number | boolean | ReadonlyArray<string> | ReadonlyArray<number> | ReadonlyArray<boolean> | null> {}
interface ParsedUrlQueryInput extends
NodeJS.Dict<
| string
| number
| boolean
| ReadonlyArray<string>
| ReadonlyArray<number>
| ReadonlyArray<boolean>
| null
>
{}
/**

@@ -131,4 +141,4 @@ * The `querystring.stringify()` method produces a URL query string from a

}
declare module 'node:querystring' {
export * from 'querystring';
declare module "node:querystring" {
export * from "querystring";
}

@@ -35,5 +35,5 @@ /**

*/
declare module 'readline' {
import { Abortable, EventEmitter } from 'node:events';
import * as promises from 'node:readline/promises';
declare module "readline" {
import { Abortable, EventEmitter } from "node:events";
import * as promises from "node:readline/promises";

@@ -106,3 +106,8 @@ export { promises };

*/
protected constructor(input: NodeJS.ReadableStream, output?: NodeJS.WritableStream, completer?: Completer | AsyncCompleter, terminal?: boolean);
protected constructor(
input: NodeJS.ReadableStream,
output?: NodeJS.WritableStream,
completer?: Completer | AsyncCompleter,
terminal?: boolean,
);
/**

@@ -268,55 +273,55 @@ * NOTE: According to the documentation:

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'line', listener: (input: string) => void): this;
addListener(event: 'pause', listener: () => void): this;
addListener(event: 'resume', listener: () => void): this;
addListener(event: 'SIGCONT', listener: () => void): this;
addListener(event: 'SIGINT', listener: () => void): this;
addListener(event: 'SIGTSTP', listener: () => void): this;
addListener(event: 'history', listener: (history: string[]) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "line", listener: (input: string) => void): this;
addListener(event: "pause", listener: () => void): this;
addListener(event: "resume", listener: () => void): this;
addListener(event: "SIGCONT", listener: () => void): this;
addListener(event: "SIGINT", listener: () => void): this;
addListener(event: "SIGTSTP", listener: () => void): this;
addListener(event: "history", listener: (history: string[]) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'line', input: string): boolean;
emit(event: 'pause'): boolean;
emit(event: 'resume'): boolean;
emit(event: 'SIGCONT'): boolean;
emit(event: 'SIGINT'): boolean;
emit(event: 'SIGTSTP'): boolean;
emit(event: 'history', history: string[]): boolean;
emit(event: "close"): boolean;
emit(event: "line", input: string): boolean;
emit(event: "pause"): boolean;
emit(event: "resume"): boolean;
emit(event: "SIGCONT"): boolean;
emit(event: "SIGINT"): boolean;
emit(event: "SIGTSTP"): boolean;
emit(event: "history", history: string[]): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'line', listener: (input: string) => void): this;
on(event: 'pause', listener: () => void): this;
on(event: 'resume', listener: () => void): this;
on(event: 'SIGCONT', listener: () => void): this;
on(event: 'SIGINT', listener: () => void): this;
on(event: 'SIGTSTP', listener: () => void): this;
on(event: 'history', listener: (history: string[]) => void): this;
on(event: "close", listener: () => void): this;
on(event: "line", listener: (input: string) => void): this;
on(event: "pause", listener: () => void): this;
on(event: "resume", listener: () => void): this;
on(event: "SIGCONT", listener: () => void): this;
on(event: "SIGINT", listener: () => void): this;
on(event: "SIGTSTP", listener: () => void): this;
on(event: "history", listener: (history: string[]) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'line', listener: (input: string) => void): this;
once(event: 'pause', listener: () => void): this;
once(event: 'resume', listener: () => void): this;
once(event: 'SIGCONT', listener: () => void): this;
once(event: 'SIGINT', listener: () => void): this;
once(event: 'SIGTSTP', listener: () => void): this;
once(event: 'history', listener: (history: string[]) => void): this;
once(event: "close", listener: () => void): this;
once(event: "line", listener: (input: string) => void): this;
once(event: "pause", listener: () => void): this;
once(event: "resume", listener: () => void): this;
once(event: "SIGCONT", listener: () => void): this;
once(event: "SIGINT", listener: () => void): this;
once(event: "SIGTSTP", listener: () => void): this;
once(event: "history", listener: (history: string[]) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'line', listener: (input: string) => void): this;
prependListener(event: 'pause', listener: () => void): this;
prependListener(event: 'resume', listener: () => void): this;
prependListener(event: 'SIGCONT', listener: () => void): this;
prependListener(event: 'SIGINT', listener: () => void): this;
prependListener(event: 'SIGTSTP', listener: () => void): this;
prependListener(event: 'history', listener: (history: string[]) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "line", listener: (input: string) => void): this;
prependListener(event: "pause", listener: () => void): this;
prependListener(event: "resume", listener: () => void): this;
prependListener(event: "SIGCONT", listener: () => void): this;
prependListener(event: "SIGINT", listener: () => void): this;
prependListener(event: "SIGTSTP", listener: () => void): this;
prependListener(event: "history", listener: (history: string[]) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'line', listener: (input: string) => void): this;
prependOnceListener(event: 'pause', listener: () => void): this;
prependOnceListener(event: 'resume', listener: () => void): this;
prependOnceListener(event: 'SIGCONT', listener: () => void): this;
prependOnceListener(event: 'SIGINT', listener: () => void): this;
prependOnceListener(event: 'SIGTSTP', listener: () => void): this;
prependOnceListener(event: 'history', listener: (history: string[]) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "line", listener: (input: string) => void): this;
prependOnceListener(event: "pause", listener: () => void): this;
prependOnceListener(event: "resume", listener: () => void): this;
prependOnceListener(event: "SIGCONT", listener: () => void): this;
prependOnceListener(event: "SIGINT", listener: () => void): this;
prependOnceListener(event: "SIGTSTP", listener: () => void): this;
prependOnceListener(event: "history", listener: (history: string[]) => void): this;
[Symbol.asyncIterator](): AsyncIterableIterator<string>;

@@ -326,3 +331,6 @@ }

export type Completer = (line: string) => CompleterResult;
export type AsyncCompleter = (line: string, callback: (err?: null | Error, result?: CompleterResult) => void) => void;
export type AsyncCompleter = (
line: string,
callback: (err?: null | Error, result?: CompleterResult) => void,
) => void;
export type CompleterResult = [string[], string];

@@ -390,3 +398,8 @@ export interface ReadLineOptions {

*/
export function createInterface(input: NodeJS.ReadableStream, output?: NodeJS.WritableStream, completer?: Completer | AsyncCompleter, terminal?: boolean): Interface;
export function createInterface(
input: NodeJS.ReadableStream,
output?: NodeJS.WritableStream,
completer?: Completer | AsyncCompleter,
terminal?: boolean,
): Interface;
export function createInterface(options: ReadLineOptions): Interface;

@@ -656,4 +669,4 @@ /**

}
declare module 'node:readline' {
export * from 'readline';
declare module "node:readline" {
export * from "readline";
}

@@ -7,5 +7,5 @@ /**

*/
declare module 'readline/promises' {
import { Interface as _Interface, ReadLineOptions, Completer, AsyncCompleter, Direction } from 'node:readline';
import { Abortable } from 'node:events';
declare module "readline/promises" {
import { AsyncCompleter, Completer, Direction, Interface as _Interface, ReadLineOptions } from "node:readline";
import { Abortable } from "node:events";

@@ -142,4 +142,4 @@ class Interface extends _Interface {

}
declare module 'node:readline/promises' {
export * from 'readline/promises';
declare module "node:readline/promises" {
export * from "readline/promises";
}

@@ -11,3 +11,3 @@ # Installation

### Additional Details
* Last updated: Wed, 20 Sep 2023 03:06:41 GMT
* Last updated: Sat, 23 Sep 2023 20:38:33 GMT
* Dependencies: none

@@ -14,0 +14,0 @@ * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`, `structuredClone`

@@ -11,6 +11,6 @@ /**

*/
declare module 'repl' {
import { Interface, Completer, AsyncCompleter } from 'node:readline';
import { Context } from 'node:vm';
import { InspectOptions } from 'node:util';
declare module "repl" {
import { AsyncCompleter, Completer, Interface } from "node:readline";
import { Context } from "node:vm";
import { InspectOptions } from "node:util";
interface ReplOptions {

@@ -103,3 +103,9 @@ /**

}
type REPLEval = (this: REPLServer, evalCmd: string, context: Context, file: string, cb: (err: Error | null, result: any) => void) => void;
type REPLEval = (
this: REPLServer,
evalCmd: string,
context: Context,
file: string,
cb: (err: Error | null, result: any) => void,
) => void;
type REPLWriter = (this: REPLServer, obj: any) => string;

@@ -331,61 +337,61 @@ /**

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'line', listener: (input: string) => void): this;
addListener(event: 'pause', listener: () => void): this;
addListener(event: 'resume', listener: () => void): this;
addListener(event: 'SIGCONT', listener: () => void): this;
addListener(event: 'SIGINT', listener: () => void): this;
addListener(event: 'SIGTSTP', listener: () => void): this;
addListener(event: 'exit', listener: () => void): this;
addListener(event: 'reset', listener: (context: Context) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "line", listener: (input: string) => void): this;
addListener(event: "pause", listener: () => void): this;
addListener(event: "resume", listener: () => void): this;
addListener(event: "SIGCONT", listener: () => void): this;
addListener(event: "SIGINT", listener: () => void): this;
addListener(event: "SIGTSTP", listener: () => void): this;
addListener(event: "exit", listener: () => void): this;
addListener(event: "reset", listener: (context: Context) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'line', input: string): boolean;
emit(event: 'pause'): boolean;
emit(event: 'resume'): boolean;
emit(event: 'SIGCONT'): boolean;
emit(event: 'SIGINT'): boolean;
emit(event: 'SIGTSTP'): boolean;
emit(event: 'exit'): boolean;
emit(event: 'reset', context: Context): boolean;
emit(event: "close"): boolean;
emit(event: "line", input: string): boolean;
emit(event: "pause"): boolean;
emit(event: "resume"): boolean;
emit(event: "SIGCONT"): boolean;
emit(event: "SIGINT"): boolean;
emit(event: "SIGTSTP"): boolean;
emit(event: "exit"): boolean;
emit(event: "reset", context: Context): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'line', listener: (input: string) => void): this;
on(event: 'pause', listener: () => void): this;
on(event: 'resume', listener: () => void): this;
on(event: 'SIGCONT', listener: () => void): this;
on(event: 'SIGINT', listener: () => void): this;
on(event: 'SIGTSTP', listener: () => void): this;
on(event: 'exit', listener: () => void): this;
on(event: 'reset', listener: (context: Context) => void): this;
on(event: "close", listener: () => void): this;
on(event: "line", listener: (input: string) => void): this;
on(event: "pause", listener: () => void): this;
on(event: "resume", listener: () => void): this;
on(event: "SIGCONT", listener: () => void): this;
on(event: "SIGINT", listener: () => void): this;
on(event: "SIGTSTP", listener: () => void): this;
on(event: "exit", listener: () => void): this;
on(event: "reset", listener: (context: Context) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'line', listener: (input: string) => void): this;
once(event: 'pause', listener: () => void): this;
once(event: 'resume', listener: () => void): this;
once(event: 'SIGCONT', listener: () => void): this;
once(event: 'SIGINT', listener: () => void): this;
once(event: 'SIGTSTP', listener: () => void): this;
once(event: 'exit', listener: () => void): this;
once(event: 'reset', listener: (context: Context) => void): this;
once(event: "close", listener: () => void): this;
once(event: "line", listener: (input: string) => void): this;
once(event: "pause", listener: () => void): this;
once(event: "resume", listener: () => void): this;
once(event: "SIGCONT", listener: () => void): this;
once(event: "SIGINT", listener: () => void): this;
once(event: "SIGTSTP", listener: () => void): this;
once(event: "exit", listener: () => void): this;
once(event: "reset", listener: (context: Context) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'line', listener: (input: string) => void): this;
prependListener(event: 'pause', listener: () => void): this;
prependListener(event: 'resume', listener: () => void): this;
prependListener(event: 'SIGCONT', listener: () => void): this;
prependListener(event: 'SIGINT', listener: () => void): this;
prependListener(event: 'SIGTSTP', listener: () => void): this;
prependListener(event: 'exit', listener: () => void): this;
prependListener(event: 'reset', listener: (context: Context) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "line", listener: (input: string) => void): this;
prependListener(event: "pause", listener: () => void): this;
prependListener(event: "resume", listener: () => void): this;
prependListener(event: "SIGCONT", listener: () => void): this;
prependListener(event: "SIGINT", listener: () => void): this;
prependListener(event: "SIGTSTP", listener: () => void): this;
prependListener(event: "exit", listener: () => void): this;
prependListener(event: "reset", listener: (context: Context) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'line', listener: (input: string) => void): this;
prependOnceListener(event: 'pause', listener: () => void): this;
prependOnceListener(event: 'resume', listener: () => void): this;
prependOnceListener(event: 'SIGCONT', listener: () => void): this;
prependOnceListener(event: 'SIGINT', listener: () => void): this;
prependOnceListener(event: 'SIGTSTP', listener: () => void): this;
prependOnceListener(event: 'exit', listener: () => void): this;
prependOnceListener(event: 'reset', listener: (context: Context) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "line", listener: (input: string) => void): this;
prependOnceListener(event: "pause", listener: () => void): this;
prependOnceListener(event: "resume", listener: () => void): this;
prependOnceListener(event: "SIGCONT", listener: () => void): this;
prependOnceListener(event: "SIGINT", listener: () => void): this;
prependOnceListener(event: "SIGTSTP", listener: () => void): this;
prependOnceListener(event: "exit", listener: () => void): this;
prependOnceListener(event: "reset", listener: (context: Context) => void): this;
}

@@ -425,4 +431,4 @@ /**

}
declare module 'node:repl' {
export * from 'repl';
declare module "node:repl" {
export * from "repl";
}

@@ -1,4 +0,4 @@

declare module 'stream/consumers' {
declare module "stream/consumers" {
import { Blob as NodeBlob } from "node:buffer";
import { Readable } from 'node:stream';
import { Readable } from "node:stream";
function buffer(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<Buffer>;

@@ -10,4 +10,4 @@ function text(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<string>;

}
declare module 'node:stream/consumers' {
export * from 'stream/consumers';
declare module "node:stream/consumers" {
export * from "stream/consumers";
}

@@ -1,12 +0,35 @@

declare module 'stream/promises' {
import { FinishedOptions, PipelineSource, PipelineTransform, PipelineDestination, PipelinePromise, PipelineOptions } from 'node:stream';
function finished(stream: NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream, options?: FinishedOptions): Promise<void>;
function pipeline<A extends PipelineSource<any>, B extends PipelineDestination<A, any>>(source: A, destination: B, options?: PipelineOptions): PipelinePromise<B>;
function pipeline<A extends PipelineSource<any>, T1 extends PipelineTransform<A, any>, B extends PipelineDestination<T1, any>>(
declare module "stream/promises" {
import {
FinishedOptions,
PipelineDestination,
PipelineOptions,
PipelinePromise,
PipelineSource,
PipelineTransform,
} from "node:stream";
function finished(
stream: NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream,
options?: FinishedOptions,
): Promise<void>;
function pipeline<A extends PipelineSource<any>, B extends PipelineDestination<A, any>>(
source: A,
destination: B,
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline<
A extends PipelineSource<any>,
T1 extends PipelineTransform<A, any>,
B extends PipelineDestination<T1, any>,
>(
source: A,
transform1: T1,
destination: B,
options?: PipelineOptions
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline<A extends PipelineSource<any>, T1 extends PipelineTransform<A, any>, T2 extends PipelineTransform<T1, any>, B extends PipelineDestination<T2, any>>(
function pipeline<
A extends PipelineSource<any>,
T1 extends PipelineTransform<A, any>,
T2 extends PipelineTransform<T1, any>,
B extends PipelineDestination<T2, any>,
>(
source: A,

@@ -16,3 +39,3 @@ transform1: T1,

destination: B,
options?: PipelineOptions
options?: PipelineOptions,
): PipelinePromise<B>;

@@ -24,4 +47,11 @@ function pipeline<

T3 extends PipelineTransform<T2, any>,
B extends PipelineDestination<T3, any>
>(source: A, transform1: T1, transform2: T2, transform3: T3, destination: B, options?: PipelineOptions): PipelinePromise<B>;
B extends PipelineDestination<T3, any>,
>(
source: A,
transform1: T1,
transform2: T2,
transform3: T3,
destination: B,
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline<

@@ -33,6 +63,17 @@ A extends PipelineSource<any>,

T4 extends PipelineTransform<T3, any>,
B extends PipelineDestination<T4, any>
>(source: A, transform1: T1, transform2: T2, transform3: T3, transform4: T4, destination: B, options?: PipelineOptions): PipelinePromise<B>;
function pipeline(streams: ReadonlyArray<NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream>, options?: PipelineOptions): Promise<void>;
B extends PipelineDestination<T4, any>,
>(
source: A,
transform1: T1,
transform2: T2,
transform3: T3,
transform4: T4,
destination: B,
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline(
streams: ReadonlyArray<NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream>,
options?: PipelineOptions,
): Promise<void>;
function pipeline(
stream1: NodeJS.ReadableStream,

@@ -43,4 +84,4 @@ stream2: NodeJS.ReadWriteStream | NodeJS.WritableStream,

}
declare module 'node:stream/promises' {
export * from 'stream/promises';
declare module "node:stream/promises" {
export * from "stream/promises";
}

@@ -1,2 +0,2 @@

declare module 'stream/web' {
declare module "stream/web" {
// stub module, pending copy&paste from .d.ts or manual impl

@@ -77,3 +77,5 @@ // copy from lib.dom.d.ts

type ReadableStreamController<T> = ReadableStreamDefaultController<T>;
type ReadableStreamDefaultReadResult<T> = ReadableStreamDefaultReadValueResult<T> | ReadableStreamDefaultReadDoneResult;
type ReadableStreamDefaultReadResult<T> =
| ReadableStreamDefaultReadValueResult<T>
| ReadableStreamDefaultReadDoneResult;
interface ReadableByteStreamControllerCallback {

@@ -117,3 +119,3 @@ (controller: ReadableByteStreamController): void | PromiseLike<void>;

start?: ReadableByteStreamControllerCallback;
type: 'bytes';
type: "bytes";
}

@@ -149,4 +151,4 @@ interface UnderlyingSource<R = any> {

prototype: ReadableStream;
new (underlyingSource: UnderlyingByteSource, strategy?: QueuingStrategy<Uint8Array>): ReadableStream<Uint8Array>;
new <R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
new(underlyingSource: UnderlyingByteSource, strategy?: QueuingStrategy<Uint8Array>): ReadableStream<Uint8Array>;
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

@@ -159,3 +161,3 @@ interface ReadableStreamDefaultReader<R = any> extends ReadableStreamGenericReader {

prototype: ReadableStreamDefaultReader;
new <R = any>(stream: ReadableStream<R>): ReadableStreamDefaultReader<R>;
new<R = any>(stream: ReadableStream<R>): ReadableStreamDefaultReader<R>;
};

@@ -173,3 +175,3 @@ const ReadableStreamBYOBReader: any;

prototype: ReadableByteStreamController;
new (): ReadableByteStreamController;
new(): ReadableByteStreamController;
};

@@ -184,3 +186,3 @@ interface ReadableStreamDefaultController<R = any> {

prototype: ReadableStreamDefaultController;
new (): ReadableStreamDefaultController;
new(): ReadableStreamDefaultController;
};

@@ -200,3 +202,7 @@ interface Transformer<I = any, O = any> {

prototype: TransformStream;
new <I = any, O = any>(transformer?: Transformer<I, O>, writableStrategy?: QueuingStrategy<I>, readableStrategy?: QueuingStrategy<O>): TransformStream<I, O>;
new<I = any, O = any>(
transformer?: Transformer<I, O>,
writableStrategy?: QueuingStrategy<I>,
readableStrategy?: QueuingStrategy<O>,
): TransformStream<I, O>;
};

@@ -211,3 +217,3 @@ interface TransformStreamDefaultController<O = any> {

prototype: TransformStreamDefaultController;
new (): TransformStreamDefaultController;
new(): TransformStreamDefaultController;
};

@@ -227,3 +233,3 @@ /**

prototype: WritableStream;
new <W = any>(underlyingSink?: UnderlyingSink<W>, strategy?: QueuingStrategy<W>): WritableStream<W>;
new<W = any>(underlyingSink?: UnderlyingSink<W>, strategy?: QueuingStrategy<W>): WritableStream<W>;
};

@@ -247,3 +253,3 @@ /**

prototype: WritableStreamDefaultWriter;
new <W = any>(stream: WritableStream<W>): WritableStreamDefaultWriter<W>;
new<W = any>(stream: WritableStream<W>): WritableStreamDefaultWriter<W>;
};

@@ -261,3 +267,3 @@ /**

prototype: WritableStreamDefaultController;
new (): WritableStreamDefaultController;
new(): WritableStreamDefaultController;
};

@@ -293,3 +299,3 @@ interface QueuingStrategy<T = any> {

prototype: ByteLengthQueuingStrategy;
new (init: QueuingStrategyInit): ByteLengthQueuingStrategy;
new(init: QueuingStrategyInit): ByteLengthQueuingStrategy;
};

@@ -306,7 +312,7 @@ /**

prototype: CountQueuingStrategy;
new (init: QueuingStrategyInit): CountQueuingStrategy;
new(init: QueuingStrategyInit): CountQueuingStrategy;
};
interface TextEncoderStream {
/** Returns "utf-8". */
readonly encoding: 'utf-8';
readonly encoding: "utf-8";
readonly readable: ReadableStream<Uint8Array>;

@@ -318,3 +324,3 @@ readonly writable: WritableStream<string>;

prototype: TextEncoderStream;
new (): TextEncoderStream;
new(): TextEncoderStream;
};

@@ -339,7 +345,7 @@ interface TextDecoderOptions {

prototype: TextDecoderStream;
new (label?: string, options?: TextDecoderOptions): TextDecoderStream;
new(label?: string, options?: TextDecoderOptions): TextDecoderStream;
};
}
declare module 'node:stream/web' {
export * from 'stream/web';
declare module "node:stream/web" {
export * from "stream/web";
}

@@ -41,3 +41,3 @@ /**

*/
declare module 'string_decoder' {
declare module "string_decoder" {
class StringDecoder {

@@ -66,4 +66,4 @@ constructor(encoding?: BufferEncoding);

}
declare module 'node:string_decoder' {
export * from 'string_decoder';
declare module "node:string_decoder" {
export * from "string_decoder";
}

@@ -5,4 +5,4 @@ /**

*/
declare module 'node:test' {
import { AsyncResource } from 'node:async_hooks';
declare module "node:test" {
import { AsyncResource } from "node:async_hooks";
/**

@@ -54,16 +54,3 @@ * Programmatically start the test runner.

namespace test {
export {
after,
afterEach,
before,
beforeEach,
describe,
it,
run,
mock,
test,
skip,
todo,
only
};
export { after, afterEach, before, beforeEach, describe, it, mock, only, run, skip, test, todo };
}

@@ -232,49 +219,49 @@ /**

interface TestsStream extends NodeJS.ReadableStream {
addListener(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
addListener(event: 'test:fail', listener: (data: TestFail) => void): this;
addListener(event: 'test:pass', listener: (data: TestPass) => void): this;
addListener(event: 'test:plan', listener: (data: TestPlan) => void): this;
addListener(event: 'test:start', listener: (data: TestStart) => void): this;
addListener(event: 'test:stderr', listener: (data: TestStderr) => void): this;
addListener(event: 'test:stdout', listener: (data: TestStdout) => void): this;
addListener(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
addListener(event: "test:fail", listener: (data: TestFail) => void): this;
addListener(event: "test:pass", listener: (data: TestPass) => void): this;
addListener(event: "test:plan", listener: (data: TestPlan) => void): this;
addListener(event: "test:start", listener: (data: TestStart) => void): this;
addListener(event: "test:stderr", listener: (data: TestStderr) => void): this;
addListener(event: "test:stdout", listener: (data: TestStdout) => void): this;
addListener(event: string, listener: (...args: any[]) => void): this;
emit(event: 'test:diagnostic', data: DiagnosticData): boolean;
emit(event: 'test:fail', data: TestFail): boolean;
emit(event: 'test:pass', data: TestPass): boolean;
emit(event: 'test:plan', data: TestPlan): boolean;
emit(event: 'test:start', data: TestStart): boolean;
emit(event: 'test:stderr', data: TestStderr): boolean;
emit(event: 'test:stdout', data: TestStdout): boolean;
emit(event: "test:diagnostic", data: DiagnosticData): boolean;
emit(event: "test:fail", data: TestFail): boolean;
emit(event: "test:pass", data: TestPass): boolean;
emit(event: "test:plan", data: TestPlan): boolean;
emit(event: "test:start", data: TestStart): boolean;
emit(event: "test:stderr", data: TestStderr): boolean;
emit(event: "test:stdout", data: TestStdout): boolean;
emit(event: string | symbol, ...args: any[]): boolean;
on(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
on(event: 'test:fail', listener: (data: TestFail) => void): this;
on(event: 'test:pass', listener: (data: TestPass) => void): this;
on(event: 'test:plan', listener: (data: TestPlan) => void): this;
on(event: 'test:start', listener: (data: TestStart) => void): this;
on(event: 'test:stderr', listener: (data: TestStderr) => void): this;
on(event: 'test:stdout', listener: (data: TestStdout) => void): this;
on(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
on(event: "test:fail", listener: (data: TestFail) => void): this;
on(event: "test:pass", listener: (data: TestPass) => void): this;
on(event: "test:plan", listener: (data: TestPlan) => void): this;
on(event: "test:start", listener: (data: TestStart) => void): this;
on(event: "test:stderr", listener: (data: TestStderr) => void): this;
on(event: "test:stdout", listener: (data: TestStdout) => void): this;
on(event: string, listener: (...args: any[]) => void): this;
once(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
once(event: 'test:fail', listener: (data: TestFail) => void): this;
once(event: 'test:pass', listener: (data: TestPass) => void): this;
once(event: 'test:plan', listener: (data: TestPlan) => void): this;
once(event: 'test:start', listener: (data: TestStart) => void): this;
once(event: 'test:stderr', listener: (data: TestStderr) => void): this;
once(event: 'test:stdout', listener: (data: TestStdout) => void): this;
once(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
once(event: "test:fail", listener: (data: TestFail) => void): this;
once(event: "test:pass", listener: (data: TestPass) => void): this;
once(event: "test:plan", listener: (data: TestPlan) => void): this;
once(event: "test:start", listener: (data: TestStart) => void): this;
once(event: "test:stderr", listener: (data: TestStderr) => void): this;
once(event: "test:stdout", listener: (data: TestStdout) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
prependListener(event: 'test:fail', listener: (data: TestFail) => void): this;
prependListener(event: 'test:pass', listener: (data: TestPass) => void): this;
prependListener(event: 'test:plan', listener: (data: TestPlan) => void): this;
prependListener(event: 'test:start', listener: (data: TestStart) => void): this;
prependListener(event: 'test:stderr', listener: (data: TestStderr) => void): this;
prependListener(event: 'test:stdout', listener: (data: TestStdout) => void): this;
prependListener(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
prependListener(event: "test:fail", listener: (data: TestFail) => void): this;
prependListener(event: "test:pass", listener: (data: TestPass) => void): this;
prependListener(event: "test:plan", listener: (data: TestPlan) => void): this;
prependListener(event: "test:start", listener: (data: TestStart) => void): this;
prependListener(event: "test:stderr", listener: (data: TestStderr) => void): this;
prependListener(event: "test:stdout", listener: (data: TestStdout) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
prependOnceListener(event: 'test:fail', listener: (data: TestFail) => void): this;
prependOnceListener(event: 'test:pass', listener: (data: TestPass) => void): this;
prependOnceListener(event: 'test:plan', listener: (data: TestPlan) => void): this;
prependOnceListener(event: 'test:start', listener: (data: TestStart) => void): this;
prependOnceListener(event: 'test:stderr', listener: (data: TestStderr) => void): this;
prependOnceListener(event: 'test:stdout', listener: (data: TestStdout) => void): this;
prependOnceListener(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
prependOnceListener(event: "test:fail", listener: (data: TestFail) => void): this;
prependOnceListener(event: "test:pass", listener: (data: TestPass) => void): this;
prependOnceListener(event: "test:plan", listener: (data: TestPlan) => void): this;
prependOnceListener(event: "test:start", listener: (data: TestStart) => void): this;
prependOnceListener(event: "test:stderr", listener: (data: TestStderr) => void): this;
prependOnceListener(event: "test:stdout", listener: (data: TestStdout) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;

@@ -560,3 +547,7 @@ }

fn<F extends Function = NoOpFunction>(original?: F, options?: MockFunctionOptions): Mock<F>;
fn<F extends Function = NoOpFunction, Implementation extends Function = F>(original?: F, implementation?: Implementation, options?: MockFunctionOptions): Mock<F | Implementation>;
fn<F extends Function = NoOpFunction, Implementation extends Function = F>(
original?: F,
implementation?: Implementation,
options?: MockFunctionOptions,
): Mock<F | Implementation>;

@@ -577,4 +568,3 @@ /**

options?: MockFunctionOptions,
): MockedObject[MethodName] extends Function
? Mock<MockedObject[MethodName]>
): MockedObject[MethodName] extends Function ? Mock<MockedObject[MethodName]>
: never;

@@ -590,4 +580,3 @@ method<

options?: MockFunctionOptions,
): MockedObject[MethodName] extends Function
? Mock<MockedObject[MethodName] | Implementation>
): MockedObject[MethodName] extends Function ? Mock<MockedObject[MethodName] | Implementation>
: never;

@@ -671,12 +660,8 @@ method<MockedObject extends object>(

F extends Function,
ReturnType = F extends (...args: any) => infer T
? T
: F extends abstract new (...args: any) => infer T
? T
: unknown,
Args = F extends (...args: infer Y) => any
? Y
: F extends abstract new (...args: infer Y) => any
? Y
: unknown[],
ReturnType = F extends (...args: any) => infer T ? T
: F extends abstract new(...args: any) => infer T ? T
: unknown,
Args = F extends (...args: infer Y) => any ? Y
: F extends abstract new(...args: infer Y) => any ? Y
: unknown[],
> {

@@ -705,3 +690,3 @@ /**

*/
target: F extends abstract new (...args: any) => any ? F : undefined;
target: F extends abstract new(...args: any) => any ? F : undefined;
/**

@@ -754,3 +739,3 @@ * The mocked function's `this` value.

export { test as default, run, test, describe, it, before, after, beforeEach, afterEach, mock };
export { after, afterEach, before, beforeEach, describe, it, mock, run, test, test as default };
}

@@ -789,3 +774,3 @@

*/
type?: 'suite';
type?: "suite";
};

@@ -830,3 +815,3 @@ /**

*/
type?: 'suite';
type?: "suite";
};

@@ -952,16 +937,16 @@ /**

*/
declare module 'node:test/reporters' {
import { Transform } from 'node:stream';
declare module "node:test/reporters" {
import { Transform } from "node:stream";
type TestEvent =
| { type: 'test:diagnostic', data: DiagnosticData }
| { type: 'test:fail', data: TestFail }
| { type: 'test:pass', data: TestPass }
| { type: 'test:plan', data: TestPlan }
| { type: 'test:start', data: TestStart }
| { type: 'test:stderr', data: TestStderr }
| { type: 'test:stdout', data: TestStdout }
| { type: 'test:enqueue'; data: TestEnqueue }
| { type: 'test:dequeue'; data: TestDequeue }
| { type: 'test:watch:drained' };
| { type: "test:diagnostic"; data: DiagnosticData }
| { type: "test:fail"; data: TestFail }
| { type: "test:pass"; data: TestPass }
| { type: "test:plan"; data: TestPlan }
| { type: "test:start"; data: TestStart }
| { type: "test:stderr"; data: TestStderr }
| { type: "test:stdout"; data: TestStdout }
| { type: "test:enqueue"; data: TestEnqueue }
| { type: "test:dequeue"; data: TestDequeue }
| { type: "test:watch:drained" };
type TestEventGenerator = AsyncGenerator<TestEvent, void>;

@@ -974,3 +959,3 @@

*/
function dot(source: TestEventGenerator): AsyncGenerator<'\n' | '.' | 'X', void>;
function dot(source: TestEventGenerator): AsyncGenerator<"\n" | "." | "X", void>;
/**

@@ -986,3 +971,3 @@ * The `tap` reporter outputs the test results in the [TAP](https://testanything.org/) format.

}
export { dot, tap, Spec as spec, TestEvent };
export { dot, Spec as spec, tap, TestEvent };
}

@@ -11,5 +11,9 @@ /**

*/
declare module 'timers' {
import { Abortable } from 'node:events';
import { setTimeout as setTimeoutPromise, setImmediate as setImmediatePromise, setInterval as setIntervalPromise } from 'node:timers/promises';
declare module "timers" {
import { Abortable } from "node:events";
import {
setImmediate as setImmediatePromise,
setInterval as setIntervalPromise,
setTimeout as setTimeoutPromise,
} from "node:timers/promises";
interface TimerOptions extends Abortable {

@@ -73,3 +77,7 @@ /**

*/
function setTimeout<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timeout;
function setTimeout<TArgs extends any[]>(
callback: (...args: TArgs) => void,
ms?: number,
...args: TArgs
): NodeJS.Timeout;
// util.promisify no rest args compability

@@ -82,3 +90,7 @@ // tslint:disable-next-line void-return

function clearTimeout(timeoutId: NodeJS.Timeout | string | number | undefined): void;
function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
function setInterval<TArgs extends any[]>(
callback: (...args: TArgs) => void,
ms?: number,
...args: TArgs
): NodeJS.Timer;
// util.promisify no rest args compability

@@ -91,3 +103,6 @@ // tslint:disable-next-line void-return

function clearInterval(intervalId: NodeJS.Timeout | string | number | undefined): void;
function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
function setImmediate<TArgs extends any[]>(
callback: (...args: TArgs) => void,
...args: TArgs
): NodeJS.Immediate;
// util.promisify no rest args compability

@@ -103,4 +118,4 @@ // tslint:disable-next-line void-return

}
declare module 'node:timers' {
export * from 'timers';
declare module "node:timers" {
export * from "timers";
}

@@ -14,4 +14,4 @@ /**

*/
declare module 'timers/promises' {
import { TimerOptions } from 'node:timers';
declare module "timers/promises" {
import { TimerOptions } from "node:timers";
/**

@@ -92,4 +92,4 @@ * ```js

}
declare module 'node:timers/promises' {
export * from 'timers/promises';
declare module "node:timers/promises" {
export * from "timers/promises";
}

@@ -11,6 +11,6 @@ /**

*/
declare module 'tls' {
import { X509Certificate } from 'node:crypto';
import * as net from 'node:net';
import * as stream from 'stream';
declare module "tls" {
import { X509Certificate } from "node:crypto";
import * as net from "node:net";
import * as stream from "stream";
const CLIENT_RENEG_LIMIT: number;

@@ -400,3 +400,3 @@ const CLIENT_RENEG_WINDOW: number;

},
callback: (err: Error | null) => void
callback: (err: Error | null) => void,
): undefined | boolean;

@@ -477,31 +477,31 @@ /**

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
addListener(event: 'secureConnect', listener: () => void): this;
addListener(event: 'session', listener: (session: Buffer) => void): this;
addListener(event: 'keylog', listener: (line: Buffer) => void): this;
addListener(event: "OCSPResponse", listener: (response: Buffer) => void): this;
addListener(event: "secureConnect", listener: () => void): this;
addListener(event: "session", listener: (session: Buffer) => void): this;
addListener(event: "keylog", listener: (line: Buffer) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'OCSPResponse', response: Buffer): boolean;
emit(event: 'secureConnect'): boolean;
emit(event: 'session', session: Buffer): boolean;
emit(event: 'keylog', line: Buffer): boolean;
emit(event: "OCSPResponse", response: Buffer): boolean;
emit(event: "secureConnect"): boolean;
emit(event: "session", session: Buffer): boolean;
emit(event: "keylog", line: Buffer): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
on(event: 'secureConnect', listener: () => void): this;
on(event: 'session', listener: (session: Buffer) => void): this;
on(event: 'keylog', listener: (line: Buffer) => void): this;
on(event: "OCSPResponse", listener: (response: Buffer) => void): this;
on(event: "secureConnect", listener: () => void): this;
on(event: "session", listener: (session: Buffer) => void): this;
on(event: "keylog", listener: (line: Buffer) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
once(event: 'secureConnect', listener: () => void): this;
once(event: 'session', listener: (session: Buffer) => void): this;
once(event: 'keylog', listener: (line: Buffer) => void): this;
once(event: "OCSPResponse", listener: (response: Buffer) => void): this;
once(event: "secureConnect", listener: () => void): this;
once(event: "session", listener: (session: Buffer) => void): this;
once(event: "keylog", listener: (line: Buffer) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
prependListener(event: 'secureConnect', listener: () => void): this;
prependListener(event: 'session', listener: (session: Buffer) => void): this;
prependListener(event: 'keylog', listener: (line: Buffer) => void): this;
prependListener(event: "OCSPResponse", listener: (response: Buffer) => void): this;
prependListener(event: "secureConnect", listener: () => void): this;
prependListener(event: "session", listener: (session: Buffer) => void): this;
prependListener(event: "keylog", listener: (line: Buffer) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
prependOnceListener(event: 'secureConnect', listener: () => void): this;
prependOnceListener(event: 'session', listener: (session: Buffer) => void): this;
prependOnceListener(event: 'keylog', listener: (line: Buffer) => void): this;
prependOnceListener(event: "OCSPResponse", listener: (response: Buffer) => void): this;
prependOnceListener(event: "secureConnect", listener: () => void): this;
prependOnceListener(event: "session", listener: (session: Buffer) => void): this;
prependOnceListener(event: "keylog", listener: (line: Buffer) => void): this;
}

@@ -567,3 +567,2 @@ interface CommonConnectionOptions {

/**
*
* @param socket

@@ -683,43 +682,114 @@ * @param identity identity parameter sent from the client.

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
addListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
addListener(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
addListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
addListener(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
addListener(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
addListener(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
addListener(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
addListener(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
addListener(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
addListener(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
addListener(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'tlsClientError', err: Error, tlsSocket: TLSSocket): boolean;
emit(event: 'newSession', sessionId: Buffer, sessionData: Buffer, callback: () => void): boolean;
emit(event: 'OCSPRequest', certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void): boolean;
emit(event: 'resumeSession', sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void): boolean;
emit(event: 'secureConnection', tlsSocket: TLSSocket): boolean;
emit(event: 'keylog', line: Buffer, tlsSocket: TLSSocket): boolean;
emit(event: "tlsClientError", err: Error, tlsSocket: TLSSocket): boolean;
emit(event: "newSession", sessionId: Buffer, sessionData: Buffer, callback: () => void): boolean;
emit(
event: "OCSPRequest",
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
): boolean;
emit(
event: "resumeSession",
sessionId: Buffer,
callback: (err: Error | null, sessionData: Buffer | null) => void,
): boolean;
emit(event: "secureConnection", tlsSocket: TLSSocket): boolean;
emit(event: "keylog", line: Buffer, tlsSocket: TLSSocket): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
on(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
on(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
on(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
on(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
on(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
on(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
on(event: "newSession", listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
on(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
on(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
on(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
on(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
once(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
once(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
once(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
once(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
once(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
once(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
once(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
once(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
once(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
once(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
once(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
prependListener(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
prependListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
prependListener(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
prependListener(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependListener(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependListener(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
prependListener(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
prependListener(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
prependListener(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
prependListener(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
prependOnceListener(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
prependOnceListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
prependOnceListener(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependOnceListener(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
prependOnceListener(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
prependOnceListener(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
prependOnceListener(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
}

@@ -733,3 +803,3 @@ /**

}
type SecureVersion = 'TLSv1.3' | 'TLSv1.2' | 'TLSv1.1' | 'TLSv1';
type SecureVersion = "TLSv1.3" | "TLSv1.2" | "TLSv1.1" | "TLSv1";
interface SecureContextOptions {

@@ -1005,3 +1075,8 @@ /**

function connect(options: ConnectionOptions, secureConnectListener?: () => void): TLSSocket;
function connect(port: number, host?: string, options?: ConnectionOptions, secureConnectListener?: () => void): TLSSocket;
function connect(
port: number,
host?: string,
options?: ConnectionOptions,
secureConnectListener?: () => void,
): TLSSocket;
function connect(port: number, options?: ConnectionOptions, secureConnectListener?: () => void): TLSSocket;

@@ -1041,3 +1116,8 @@ /**

*/
function createSecurePair(context?: SecureContext, isServer?: boolean, requestCert?: boolean, rejectUnauthorized?: boolean): SecurePair;
function createSecurePair(
context?: SecureContext,
isServer?: boolean,
requestCert?: boolean,
rejectUnauthorized?: boolean,
): SecurePair;
/**

@@ -1117,4 +1197,4 @@ * {@link createServer} sets the default value of the `honorCipherOrder` option

}
declare module 'node:tls' {
export * from 'tls';
declare module "node:tls" {
export * from "tls";
}

@@ -88,3 +88,3 @@ /**

*/
declare module 'trace_events' {
declare module "trace_events" {
/**

@@ -170,4 +170,4 @@ * The `Tracing` object is used to enable or disable tracing for sets of

}
declare module 'node:trace_events' {
export * from 'trace_events';
declare module "node:trace_events" {
export * from "trace_events";
}

@@ -6,3 +6,3 @@ /**

*/
declare module 'assert' {
declare module "assert" {
/**

@@ -24,3 +24,3 @@ * An alias of {@link ok}.

generatedMessage: boolean;
code: 'ERR_ASSERTION';
code: "ERR_ASSERTION";
constructor(options?: {

@@ -191,3 +191,3 @@ /** If provided, the error message is set to this value. */

}
type AssertPredicate = RegExp | (new () => object) | ((thrown: unknown) => boolean) | object | Error;
type AssertPredicate = RegExp | (new() => object) | ((thrown: unknown) => boolean) | object | Error;
/**

@@ -224,3 +224,3 @@ * Throws an `AssertionError` with the provided error message or a default

// tslint:disable-next-line:ban-types
stackStartFn?: Function
stackStartFn?: Function,
): never;

@@ -853,3 +853,7 @@ /**

function rejects(block: (() => Promise<unknown>) | Promise<unknown>, message?: string | Error): Promise<void>;
function rejects(block: (() => Promise<unknown>) | Promise<unknown>, error: AssertPredicate, message?: string | Error): Promise<void>;
function rejects(
block: (() => Promise<unknown>) | Promise<unknown>,
error: AssertPredicate,
message?: string | Error,
): Promise<void>;
/**

@@ -897,4 +901,11 @@ * Awaits the `asyncFn` promise or, if `asyncFn` is a function, immediately

*/
function doesNotReject(block: (() => Promise<unknown>) | Promise<unknown>, message?: string | Error): Promise<void>;
function doesNotReject(block: (() => Promise<unknown>) | Promise<unknown>, error: AssertPredicate, message?: string | Error): Promise<void>;
function doesNotReject(
block: (() => Promise<unknown>) | Promise<unknown>,
message?: string | Error,
): Promise<void>;
function doesNotReject(
block: (() => Promise<unknown>) | Promise<unknown>,
error: AssertPredicate,
message?: string | Error,
): Promise<void>;
/**

@@ -946,23 +957,36 @@ * Expects the `string` input to match the regular expression.

function doesNotMatch(value: string, regExp: RegExp, message?: string | Error): void;
const strict: Omit<typeof assert, 'equal' | 'notEqual' | 'deepEqual' | 'notDeepEqual' | 'ok' | 'strictEqual' | 'deepStrictEqual' | 'ifError' | 'strict'> & {
(value: unknown, message?: string | Error): asserts value;
equal: typeof strictEqual;
notEqual: typeof notStrictEqual;
deepEqual: typeof deepStrictEqual;
notDeepEqual: typeof notDeepStrictEqual;
// Mapped types and assertion functions are incompatible?
// TS2775: Assertions require every name in the call target
// to be declared with an explicit type annotation.
ok: typeof ok;
strictEqual: typeof strictEqual;
deepStrictEqual: typeof deepStrictEqual;
ifError: typeof ifError;
strict: typeof strict;
};
const strict:
& Omit<
typeof assert,
| "equal"
| "notEqual"
| "deepEqual"
| "notDeepEqual"
| "ok"
| "strictEqual"
| "deepStrictEqual"
| "ifError"
| "strict"
>
& {
(value: unknown, message?: string | Error): asserts value;
equal: typeof strictEqual;
notEqual: typeof notStrictEqual;
deepEqual: typeof deepStrictEqual;
notDeepEqual: typeof notDeepStrictEqual;
// Mapped types and assertion functions are incompatible?
// TS2775: Assertions require every name in the call target
// to be declared with an explicit type annotation.
ok: typeof ok;
strictEqual: typeof strictEqual;
deepStrictEqual: typeof deepStrictEqual;
ifError: typeof ifError;
strict: typeof strict;
};
}
export = assert;
}
declare module 'node:assert' {
import assert = require('assert');
declare module "node:assert" {
import assert = require("assert");
export = assert;
}

@@ -1,8 +0,8 @@

declare module 'assert/strict' {
import { strict } from 'node:assert';
declare module "assert/strict" {
import { strict } from "node:assert";
export = strict;
}
declare module 'node:assert/strict' {
import { strict } from 'node:assert';
declare module "node:assert/strict" {
import { strict } from "node:assert";
export = strict;
}

@@ -11,3 +11,3 @@ /**

*/
declare module 'async_hooks' {
declare module "async_hooks" {
/**

@@ -277,3 +277,3 @@ * ```js

type?: string,
thisArg?: ThisArg
thisArg?: ThisArg,
): Func & {

@@ -291,3 +291,3 @@ asyncResource: AsyncResource;

bind<Func extends (...args: any[]) => any>(
fn: Func
fn: Func,
): Func & {

@@ -306,3 +306,7 @@ asyncResource: AsyncResource;

*/
runInAsyncScope<This, Result>(fn: (this: This, ...args: any[]) => Result, thisArg?: This, ...args: any[]): Result;
runInAsyncScope<This, Result>(
fn: (this: This, ...args: any[]) => Result,
thisArg?: This,
...args: any[]
): Result;
/**

@@ -321,3 +325,2 @@ * Call all `destroy` hooks. This should only ever be called once. An error will

/**
*
* @return The same `triggerAsyncId` that is passed to the `AsyncResource` constructor.

@@ -522,4 +525,4 @@ */

}
declare module 'node:async_hooks' {
export * from 'async_hooks';
declare module "node:async_hooks" {
export * from "async_hooks";
}

@@ -55,7 +55,7 @@ /**

*/
declare module 'cluster' {
import * as child from 'node:child_process';
import EventEmitter = require('node:events');
import * as net from 'node:net';
type SerializationType = 'json' | 'advanced';
declare module "cluster" {
import * as child from "node:child_process";
import EventEmitter = require("node:events");
import * as net from "node:net";
type SerializationType = "json" | "advanced";
export interface ClusterSettings {

@@ -77,3 +77,3 @@ execArgv?: string[] | undefined; // default: process.execArgv

port: number;
addressType: number | 'udp4' | 'udp6'; // 4, 6, -1, "udp4", "udp6"
addressType: number | "udp4" | "udp6"; // 4, 6, -1, "udp4", "udp6"
}

@@ -130,4 +130,13 @@ /**

send(message: child.Serializable, callback?: (error: Error | null) => void): boolean;
send(message: child.Serializable, sendHandle: child.SendHandle, callback?: (error: Error | null) => void): boolean;
send(message: child.Serializable, sendHandle: child.SendHandle, options?: child.MessageOptions, callback?: (error: Error | null) => void): boolean;
send(
message: child.Serializable,
sendHandle: child.SendHandle,
callback?: (error: Error | null) => void,
): boolean;
send(
message: child.Serializable,
sendHandle: child.SendHandle,
options?: child.MessageOptions,
callback?: (error: Error | null) => void,
): boolean;
/**

@@ -289,43 +298,43 @@ * This function will kill the worker. In the primary worker, it does this by

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'disconnect', listener: () => void): this;
addListener(event: 'error', listener: (error: Error) => void): this;
addListener(event: 'exit', listener: (code: number, signal: string) => void): this;
addListener(event: 'listening', listener: (address: Address) => void): this;
addListener(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: 'online', listener: () => void): this;
addListener(event: "disconnect", listener: () => void): this;
addListener(event: "error", listener: (error: Error) => void): this;
addListener(event: "exit", listener: (code: number, signal: string) => void): this;
addListener(event: "listening", listener: (address: Address) => void): this;
addListener(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: "online", listener: () => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'disconnect'): boolean;
emit(event: 'error', error: Error): boolean;
emit(event: 'exit', code: number, signal: string): boolean;
emit(event: 'listening', address: Address): boolean;
emit(event: 'message', message: any, handle: net.Socket | net.Server): boolean;
emit(event: 'online'): boolean;
emit(event: "disconnect"): boolean;
emit(event: "error", error: Error): boolean;
emit(event: "exit", code: number, signal: string): boolean;
emit(event: "listening", address: Address): boolean;
emit(event: "message", message: any, handle: net.Socket | net.Server): boolean;
emit(event: "online"): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'disconnect', listener: () => void): this;
on(event: 'error', listener: (error: Error) => void): this;
on(event: 'exit', listener: (code: number, signal: string) => void): this;
on(event: 'listening', listener: (address: Address) => void): this;
on(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: 'online', listener: () => void): this;
on(event: "disconnect", listener: () => void): this;
on(event: "error", listener: (error: Error) => void): this;
on(event: "exit", listener: (code: number, signal: string) => void): this;
on(event: "listening", listener: (address: Address) => void): this;
on(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: "online", listener: () => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'disconnect', listener: () => void): this;
once(event: 'error', listener: (error: Error) => void): this;
once(event: 'exit', listener: (code: number, signal: string) => void): this;
once(event: 'listening', listener: (address: Address) => void): this;
once(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: 'online', listener: () => void): this;
once(event: "disconnect", listener: () => void): this;
once(event: "error", listener: (error: Error) => void): this;
once(event: "exit", listener: (code: number, signal: string) => void): this;
once(event: "listening", listener: (address: Address) => void): this;
once(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: "online", listener: () => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'disconnect', listener: () => void): this;
prependListener(event: 'error', listener: (error: Error) => void): this;
prependListener(event: 'exit', listener: (code: number, signal: string) => void): this;
prependListener(event: 'listening', listener: (address: Address) => void): this;
prependListener(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependListener(event: 'online', listener: () => void): this;
prependListener(event: "disconnect", listener: () => void): this;
prependListener(event: "error", listener: (error: Error) => void): this;
prependListener(event: "exit", listener: (code: number, signal: string) => void): this;
prependListener(event: "listening", listener: (address: Address) => void): this;
prependListener(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependListener(event: "online", listener: () => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'disconnect', listener: () => void): this;
prependOnceListener(event: 'error', listener: (error: Error) => void): this;
prependOnceListener(event: 'exit', listener: (code: number, signal: string) => void): this;
prependOnceListener(event: 'listening', listener: (address: Address) => void): this;
prependOnceListener(event: 'message', listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependOnceListener(event: 'online', listener: () => void): this;
prependOnceListener(event: "disconnect", listener: () => void): this;
prependOnceListener(event: "error", listener: (error: Error) => void): this;
prependOnceListener(event: "exit", listener: (code: number, signal: string) => void): this;
prependOnceListener(event: "listening", listener: (address: Address) => void): this;
prependOnceListener(event: "message", listener: (message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
prependOnceListener(event: "online", listener: () => void): this;
}

@@ -362,51 +371,60 @@ export interface Cluster extends EventEmitter {

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'disconnect', listener: (worker: Worker) => void): this;
addListener(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
addListener(event: 'fork', listener: (worker: Worker) => void): this;
addListener(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
addListener(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: 'online', listener: (worker: Worker) => void): this;
addListener(event: 'setup', listener: (settings: ClusterSettings) => void): this;
addListener(event: "disconnect", listener: (worker: Worker) => void): this;
addListener(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
addListener(event: "fork", listener: (worker: Worker) => void): this;
addListener(event: "listening", listener: (worker: Worker, address: Address) => void): this;
addListener(
event: "message",
listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void,
): this; // the handle is a net.Socket or net.Server object, or undefined.
addListener(event: "online", listener: (worker: Worker) => void): this;
addListener(event: "setup", listener: (settings: ClusterSettings) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'disconnect', worker: Worker): boolean;
emit(event: 'exit', worker: Worker, code: number, signal: string): boolean;
emit(event: 'fork', worker: Worker): boolean;
emit(event: 'listening', worker: Worker, address: Address): boolean;
emit(event: 'message', worker: Worker, message: any, handle: net.Socket | net.Server): boolean;
emit(event: 'online', worker: Worker): boolean;
emit(event: 'setup', settings: ClusterSettings): boolean;
emit(event: "disconnect", worker: Worker): boolean;
emit(event: "exit", worker: Worker, code: number, signal: string): boolean;
emit(event: "fork", worker: Worker): boolean;
emit(event: "listening", worker: Worker, address: Address): boolean;
emit(event: "message", worker: Worker, message: any, handle: net.Socket | net.Server): boolean;
emit(event: "online", worker: Worker): boolean;
emit(event: "setup", settings: ClusterSettings): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'disconnect', listener: (worker: Worker) => void): this;
on(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
on(event: 'fork', listener: (worker: Worker) => void): this;
on(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
on(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: 'online', listener: (worker: Worker) => void): this;
on(event: 'setup', listener: (settings: ClusterSettings) => void): this;
on(event: "disconnect", listener: (worker: Worker) => void): this;
on(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
on(event: "fork", listener: (worker: Worker) => void): this;
on(event: "listening", listener: (worker: Worker, address: Address) => void): this;
on(event: "message", listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
on(event: "online", listener: (worker: Worker) => void): this;
on(event: "setup", listener: (settings: ClusterSettings) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'disconnect', listener: (worker: Worker) => void): this;
once(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
once(event: 'fork', listener: (worker: Worker) => void): this;
once(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
once(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: 'online', listener: (worker: Worker) => void): this;
once(event: 'setup', listener: (settings: ClusterSettings) => void): this;
once(event: "disconnect", listener: (worker: Worker) => void): this;
once(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
once(event: "fork", listener: (worker: Worker) => void): this;
once(event: "listening", listener: (worker: Worker, address: Address) => void): this;
once(event: "message", listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this; // the handle is a net.Socket or net.Server object, or undefined.
once(event: "online", listener: (worker: Worker) => void): this;
once(event: "setup", listener: (settings: ClusterSettings) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'disconnect', listener: (worker: Worker) => void): this;
prependListener(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
prependListener(event: 'fork', listener: (worker: Worker) => void): this;
prependListener(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
prependListener(event: "disconnect", listener: (worker: Worker) => void): this;
prependListener(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
prependListener(event: "fork", listener: (worker: Worker) => void): this;
prependListener(event: "listening", listener: (worker: Worker, address: Address) => void): this;
// the handle is a net.Socket or net.Server object, or undefined.
prependListener(event: 'message', listener: (worker: Worker, message: any, handle?: net.Socket | net.Server) => void): this;
prependListener(event: 'online', listener: (worker: Worker) => void): this;
prependListener(event: 'setup', listener: (settings: ClusterSettings) => void): this;
prependListener(
event: "message",
listener: (worker: Worker, message: any, handle?: net.Socket | net.Server) => void,
): this;
prependListener(event: "online", listener: (worker: Worker) => void): this;
prependListener(event: "setup", listener: (settings: ClusterSettings) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'disconnect', listener: (worker: Worker) => void): this;
prependOnceListener(event: 'exit', listener: (worker: Worker, code: number, signal: string) => void): this;
prependOnceListener(event: 'fork', listener: (worker: Worker) => void): this;
prependOnceListener(event: 'listening', listener: (worker: Worker, address: Address) => void): this;
prependOnceListener(event: "disconnect", listener: (worker: Worker) => void): this;
prependOnceListener(event: "exit", listener: (worker: Worker, code: number, signal: string) => void): this;
prependOnceListener(event: "fork", listener: (worker: Worker) => void): this;
prependOnceListener(event: "listening", listener: (worker: Worker, address: Address) => void): this;
// the handle is a net.Socket or net.Server object, or undefined.
prependOnceListener(event: 'message', listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void): this;
prependOnceListener(event: 'online', listener: (worker: Worker) => void): this;
prependOnceListener(event: 'setup', listener: (settings: ClusterSettings) => void): this;
prependOnceListener(
event: "message",
listener: (worker: Worker, message: any, handle: net.Socket | net.Server) => void,
): this;
prependOnceListener(event: "online", listener: (worker: Worker) => void): this;
prependOnceListener(event: "setup", listener: (settings: ClusterSettings) => void): this;
}

@@ -416,5 +434,5 @@ const cluster: Cluster;

}
declare module 'node:cluster' {
export * from 'cluster';
export { default as default } from 'cluster';
declare module "node:cluster" {
export * from "cluster";
export { default as default } from "cluster";
}

@@ -58,8 +58,8 @@ /**

*/
declare module 'console' {
import console = require('node:console');
declare module "console" {
import console = require("node:console");
export = console;
}
declare module 'node:console' {
import { InspectOptions } from 'node:util';
declare module "node:console" {
import { InspectOptions } from "node:util";
global {

@@ -396,3 +396,3 @@ // This needs to be global to avoid TS2403 in case lib.dom.d.ts is present in the same build

ignoreErrors?: boolean | undefined;
colorMode?: boolean | 'auto' | undefined;
colorMode?: boolean | "auto" | undefined;
inspectOptions?: InspectOptions | undefined;

@@ -407,4 +407,4 @@ /**

prototype: Console;
new (stdout: NodeJS.WritableStream, stderr?: NodeJS.WritableStream, ignoreErrors?: boolean): Console;
new (options: ConsoleConstructorOptions): Console;
new(stdout: NodeJS.WritableStream, stderr?: NodeJS.WritableStream, ignoreErrors?: boolean): Console;
new(options: ConsoleConstructorOptions): Console;
}

@@ -411,0 +411,0 @@ }

/** @deprecated since v6.3.0 - use constants property exposed by the relevant module instead. */
declare module 'constants' {
import { constants as osConstants, SignalConstants } from 'node:os';
import { constants as cryptoConstants } from 'node:crypto';
import { constants as fsConstants } from 'node:fs';
declare module "constants" {
import { constants as osConstants, SignalConstants } from "node:os";
import { constants as cryptoConstants } from "node:crypto";
import { constants as fsConstants } from "node:fs";
const exp: typeof osConstants.errno &
typeof osConstants.priority &
SignalConstants &
typeof cryptoConstants &
typeof fsConstants;
const exp:
& typeof osConstants.errno
& typeof osConstants.priority
& SignalConstants
& typeof cryptoConstants
& typeof fsConstants;
export = exp;
}
declare module 'node:constants' {
import constants = require('constants');
declare module "node:constants" {
import constants = require("constants");
export = constants;
}

@@ -28,9 +28,9 @@ /**

*/
declare module 'dgram' {
import { AddressInfo } from 'node:net';
import * as dns from 'node:dns';
import { EventEmitter, Abortable } from 'node:events';
declare module "dgram" {
import { AddressInfo } from "node:net";
import * as dns from "node:dns";
import { Abortable, EventEmitter } from "node:events";
interface RemoteInfo {
address: string;
family: 'IPv4' | 'IPv6';
family: "IPv4" | "IPv6";
port: number;

@@ -45,3 +45,3 @@ size: number;

}
type SocketType = 'udp4' | 'udp6';
type SocketType = "udp4" | "udp6";
interface SocketOptions extends Abortable {

@@ -56,3 +56,9 @@ type: SocketType;

sendBufferSize?: number | undefined;
lookup?: ((hostname: string, options: dns.LookupOneOptions, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void) => void) | undefined;
lookup?:
| ((
hostname: string,
options: dns.LookupOneOptions,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
) => void)
| undefined;
}

@@ -341,8 +347,38 @@ /**

*/
send(msg: string | Uint8Array | ReadonlyArray<any>, port?: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array | ReadonlyArray<any>, port?: number, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array | ReadonlyArray<any>, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array, offset: number, length: number, port?: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array, offset: number, length: number, port?: number, callback?: (error: Error | null, bytes: number) => void): void;
send(msg: string | Uint8Array, offset: number, length: number, callback?: (error: Error | null, bytes: number) => void): void;
send(
msg: string | Uint8Array | ReadonlyArray<any>,
port?: number,
address?: string,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array | ReadonlyArray<any>,
port?: number,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array | ReadonlyArray<any>,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array,
offset: number,
length: number,
port?: number,
address?: string,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array,
offset: number,
length: number,
port?: number,
callback?: (error: Error | null, bytes: number) => void,
): void;
send(
msg: string | Uint8Array,
offset: number,
length: number,
callback?: (error: Error | null, bytes: number) => void,
): void;
/**

@@ -510,41 +546,41 @@ * Sets or clears the `SO_BROADCAST` socket option. When set to `true`, UDP

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'connect', listener: () => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'listening', listener: () => void): this;
addListener(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "connect", listener: () => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "listening", listener: () => void): this;
addListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'connect'): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'listening'): boolean;
emit(event: 'message', msg: Buffer, rinfo: RemoteInfo): boolean;
emit(event: "close"): boolean;
emit(event: "connect"): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "listening"): boolean;
emit(event: "message", msg: Buffer, rinfo: RemoteInfo): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'connect', listener: () => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'listening', listener: () => void): this;
on(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
on(event: "close", listener: () => void): this;
on(event: "connect", listener: () => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "listening", listener: () => void): this;
on(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'connect', listener: () => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'listening', listener: () => void): this;
once(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
once(event: "close", listener: () => void): this;
once(event: "connect", listener: () => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "listening", listener: () => void): this;
once(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'connect', listener: () => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'listening', listener: () => void): this;
prependListener(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "connect", listener: () => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "listening", listener: () => void): this;
prependListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'connect', listener: () => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'listening', listener: () => void): this;
prependOnceListener(event: 'message', listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "connect", listener: () => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "listening", listener: () => void): this;
prependOnceListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
}
}
declare module 'node:dgram' {
export * from 'dgram';
declare module "node:dgram" {
export * from "dgram";
}

@@ -25,3 +25,3 @@ /**

*/
declare module 'diagnostics_channel' {
declare module "diagnostics_channel" {
/**

@@ -191,4 +191,4 @@ * Check if there are active subscribers to the named channel. This is helpful if

}
declare module 'node:diagnostics_channel' {
export * from 'diagnostics_channel';
declare module "node:diagnostics_channel" {
export * from "diagnostics_channel";
}

@@ -47,4 +47,4 @@ /**

*/
declare module 'dns' {
import * as dnsPromises from 'node:dns/promises';
declare module "dns" {
import * as dnsPromises from "node:dns/promises";
// Supported getaddrinfo flags.

@@ -119,7 +119,26 @@ export const ADDRCONFIG: number;

*/
export function lookup(hostname: string, family: number, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void): void;
export function lookup(hostname: string, options: LookupOneOptions, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void): void;
export function lookup(hostname: string, options: LookupAllOptions, callback: (err: NodeJS.ErrnoException | null, addresses: LookupAddress[]) => void): void;
export function lookup(hostname: string, options: LookupOptions, callback: (err: NodeJS.ErrnoException | null, address: string | LookupAddress[], family: number) => void): void;
export function lookup(hostname: string, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void): void;
export function lookup(
hostname: string,
family: number,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
): void;
export function lookup(
hostname: string,
options: LookupOneOptions,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
): void;
export function lookup(
hostname: string,
options: LookupAllOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: LookupAddress[]) => void,
): void;
export function lookup(
hostname: string,
options: LookupOptions,
callback: (err: NodeJS.ErrnoException | null, address: string | LookupAddress[], family: number) => void,
): void;
export function lookup(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
): void;
export namespace lookup {

@@ -150,7 +169,11 @@ function __promisify__(hostname: string, options: LookupAllOptions): Promise<LookupAddress[]>;

*/
export function lookupService(address: string, port: number, callback: (err: NodeJS.ErrnoException | null, hostname: string, service: string) => void): void;
export function lookupService(
address: string,
port: number,
callback: (err: NodeJS.ErrnoException | null, hostname: string, service: string) => void,
): void;
export namespace lookupService {
function __promisify__(
address: string,
port: number
port: number,
): Promise<{

@@ -174,6 +197,6 @@ hostname: string;

export interface AnyARecord extends RecordWithTtl {
type: 'A';
type: "A";
}
export interface AnyAaaaRecord extends RecordWithTtl {
type: 'AAAA';
type: "AAAA";
}

@@ -193,3 +216,3 @@ export interface CaaRecord {

export interface AnyMxRecord extends MxRecord {
type: 'MX';
type: "MX";
}

@@ -205,3 +228,3 @@ export interface NaptrRecord {

export interface AnyNaptrRecord extends NaptrRecord {
type: 'NAPTR';
type: "NAPTR";
}

@@ -218,3 +241,3 @@ export interface SoaRecord {

export interface AnySoaRecord extends SoaRecord {
type: 'SOA';
type: "SOA";
}

@@ -228,21 +251,31 @@ export interface SrvRecord {

export interface AnySrvRecord extends SrvRecord {
type: 'SRV';
type: "SRV";
}
export interface AnyTxtRecord {
type: 'TXT';
type: "TXT";
entries: string[];
}
export interface AnyNsRecord {
type: 'NS';
type: "NS";
value: string;
}
export interface AnyPtrRecord {
type: 'PTR';
type: "PTR";
value: string;
}
export interface AnyCnameRecord {
type: 'CNAME';
type: "CNAME";
value: string;
}
export type AnyRecord = AnyARecord | AnyAaaaRecord | AnyCnameRecord | AnyMxRecord | AnyNaptrRecord | AnyNsRecord | AnyPtrRecord | AnySoaRecord | AnySrvRecord | AnyTxtRecord;
export type AnyRecord =
| AnyARecord
| AnyAaaaRecord
| AnyCnameRecord
| AnyMxRecord
| AnyNaptrRecord
| AnyNsRecord
| AnyPtrRecord
| AnySoaRecord
| AnySrvRecord
| AnyTxtRecord;
/**

@@ -260,28 +293,81 @@ * Uses the DNS protocol to resolve a host name (e.g. `'nodejs.org'`) into an array

*/
export function resolve(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'A', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'AAAA', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'ANY', callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'CNAME', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'MX', callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'NAPTR', callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'NS', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'PTR', callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve(hostname: string, rrtype: 'SOA', callback: (err: NodeJS.ErrnoException | null, addresses: SoaRecord) => void): void;
export function resolve(hostname: string, rrtype: 'SRV', callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void): void;
export function resolve(hostname: string, rrtype: 'TXT', callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void): void;
export function resolve(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "A",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "AAAA",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "ANY",
callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "CNAME",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "MX",
callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "NAPTR",
callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "NS",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "PTR",
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "SOA",
callback: (err: NodeJS.ErrnoException | null, addresses: SoaRecord) => void,
): void;
export function resolve(
hostname: string,
rrtype: "SRV",
callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void,
): void;
export function resolve(
hostname: string,
rrtype: "TXT",
callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void,
): void;
export function resolve(
hostname: string,
rrtype: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]) => void
callback: (
err: NodeJS.ErrnoException | null,
addresses: string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[],
) => void,
): void;
export namespace resolve {
function __promisify__(hostname: string, rrtype?: 'A' | 'AAAA' | 'CNAME' | 'NS' | 'PTR'): Promise<string[]>;
function __promisify__(hostname: string, rrtype: 'ANY'): Promise<AnyRecord[]>;
function __promisify__(hostname: string, rrtype: 'MX'): Promise<MxRecord[]>;
function __promisify__(hostname: string, rrtype: 'NAPTR'): Promise<NaptrRecord[]>;
function __promisify__(hostname: string, rrtype: 'SOA'): Promise<SoaRecord>;
function __promisify__(hostname: string, rrtype: 'SRV'): Promise<SrvRecord[]>;
function __promisify__(hostname: string, rrtype: 'TXT'): Promise<string[][]>;
function __promisify__(hostname: string, rrtype: string): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
function __promisify__(hostname: string, rrtype?: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
function __promisify__(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
function __promisify__(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
function __promisify__(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
function __promisify__(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
function __promisify__(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
function __promisify__(hostname: string, rrtype: "TXT"): Promise<string[][]>;
function __promisify__(
hostname: string,
rrtype: string,
): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
}

@@ -294,5 +380,16 @@ /**

*/
export function resolve4(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve4(hostname: string, options: ResolveWithTtlOptions, callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void): void;
export function resolve4(hostname: string, options: ResolveOptions, callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void): void;
export function resolve4(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve4(
hostname: string,
options: ResolveWithTtlOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void,
): void;
export function resolve4(
hostname: string,
options: ResolveOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void,
): void;
export namespace resolve4 {

@@ -309,5 +406,16 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolve6(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolve6(hostname: string, options: ResolveWithTtlOptions, callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void): void;
export function resolve6(hostname: string, options: ResolveOptions, callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void): void;
export function resolve6(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export function resolve6(
hostname: string,
options: ResolveWithTtlOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: RecordWithTtl[]) => void,
): void;
export function resolve6(
hostname: string,
options: ResolveOptions,
callback: (err: NodeJS.ErrnoException | null, addresses: string[] | RecordWithTtl[]) => void,
): void;
export namespace resolve6 {

@@ -323,3 +431,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolveCname(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolveCname(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export namespace resolveCname {

@@ -334,3 +445,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolveCaa(hostname: string, callback: (err: NodeJS.ErrnoException | null, records: CaaRecord[]) => void): void;
export function resolveCaa(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, records: CaaRecord[]) => void,
): void;
export namespace resolveCaa {

@@ -344,3 +458,6 @@ function __promisify__(hostname: string): Promise<CaaRecord[]>;

*/
export function resolveMx(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void): void;
export function resolveMx(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: MxRecord[]) => void,
): void;
export namespace resolveMx {

@@ -372,3 +489,6 @@ function __promisify__(hostname: string): Promise<MxRecord[]>;

*/
export function resolveNaptr(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void): void;
export function resolveNaptr(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void,
): void;
export namespace resolveNaptr {

@@ -382,3 +502,6 @@ function __promisify__(hostname: string): Promise<NaptrRecord[]>;

*/
export function resolveNs(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolveNs(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export namespace resolveNs {

@@ -392,3 +515,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolvePtr(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void): void;
export function resolvePtr(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
): void;
export namespace resolvePtr {

@@ -423,3 +549,6 @@ function __promisify__(hostname: string): Promise<string[]>;

*/
export function resolveSoa(hostname: string, callback: (err: NodeJS.ErrnoException | null, address: SoaRecord) => void): void;
export function resolveSoa(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, address: SoaRecord) => void,
): void;
export namespace resolveSoa {

@@ -447,3 +576,6 @@ function __promisify__(hostname: string): Promise<SoaRecord>;

*/
export function resolveSrv(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void): void;
export function resolveSrv(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: SrvRecord[]) => void,
): void;
export namespace resolveSrv {

@@ -459,3 +591,6 @@ function __promisify__(hostname: string): Promise<SrvRecord[]>;

*/
export function resolveTxt(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void): void;
export function resolveTxt(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: string[][]) => void,
): void;
export namespace resolveTxt {

@@ -494,3 +629,6 @@ function __promisify__(hostname: string): Promise<string[][]>;

*/
export function resolveAny(hostname: string, callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void): void;
export function resolveAny(
hostname: string,
callback: (err: NodeJS.ErrnoException | null, addresses: AnyRecord[]) => void,
): void;
export namespace resolveAny {

@@ -507,3 +645,6 @@ function __promisify__(hostname: string): Promise<AnyRecord[]>;

*/
export function reverse(ip: string, callback: (err: NodeJS.ErrnoException | null, hostnames: string[]) => void): void;
export function reverse(
ip: string,
callback: (err: NodeJS.ErrnoException | null, hostnames: string[]) => void,
): void;
/**

@@ -516,3 +657,3 @@ * Get the default value for `verbatim` in {@link lookup} and `dnsPromises.lookup()`. The value could be:

*/
export function getDefaultResultOrder(): 'ipv4first' | 'verbatim';
export function getDefaultResultOrder(): "ipv4first" | "verbatim";
/**

@@ -575,3 +716,3 @@ * Sets the IP address and port of servers to be used when performing DNS

*/
export function setDefaultResultOrder(order: 'ipv4first' | 'verbatim'): void;
export function setDefaultResultOrder(order: "ipv4first" | "verbatim"): void;
// Error codes

@@ -690,4 +831,4 @@ export const NODATA: string;

}
declare module 'node:dns' {
export * from 'dns';
declare module "node:dns" {
export * from "dns";
}

@@ -7,19 +7,19 @@ /**

*/
declare module 'dns/promises' {
declare module "dns/promises" {
import {
AnyRecord,
CaaRecord,
LookupAddress,
LookupAllOptions,
LookupOneOptions,
LookupAllOptions,
LookupOptions,
AnyRecord,
CaaRecord,
MxRecord,
NaptrRecord,
SoaRecord,
SrvRecord,
ResolveWithTtlOptions,
RecordWithTtl,
ResolveOptions,
ResolverOptions,
} from 'node:dns';
ResolveWithTtlOptions,
SoaRecord,
SrvRecord,
} from "node:dns";
/**

@@ -110,3 +110,3 @@ * Returns an array of IP address strings, formatted according to [RFC 5952](https://tools.ietf.org/html/rfc5952#section-6),

address: string,
port: number
port: number,
): Promise<{

@@ -130,15 +130,18 @@ hostname: string;

function resolve(hostname: string): Promise<string[]>;
function resolve(hostname: string, rrtype: 'A'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'AAAA'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'ANY'): Promise<AnyRecord[]>;
function resolve(hostname: string, rrtype: 'CAA'): Promise<CaaRecord[]>;
function resolve(hostname: string, rrtype: 'CNAME'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'MX'): Promise<MxRecord[]>;
function resolve(hostname: string, rrtype: 'NAPTR'): Promise<NaptrRecord[]>;
function resolve(hostname: string, rrtype: 'NS'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'PTR'): Promise<string[]>;
function resolve(hostname: string, rrtype: 'SOA'): Promise<SoaRecord>;
function resolve(hostname: string, rrtype: 'SRV'): Promise<SrvRecord[]>;
function resolve(hostname: string, rrtype: 'TXT'): Promise<string[][]>;
function resolve(hostname: string, rrtype: string): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
function resolve(hostname: string, rrtype: "A"): Promise<string[]>;
function resolve(hostname: string, rrtype: "AAAA"): Promise<string[]>;
function resolve(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
function resolve(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
function resolve(hostname: string, rrtype: "CNAME"): Promise<string[]>;
function resolve(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
function resolve(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
function resolve(hostname: string, rrtype: "NS"): Promise<string[]>;
function resolve(hostname: string, rrtype: "PTR"): Promise<string[]>;
function resolve(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
function resolve(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
function resolve(hostname: string, rrtype: "TXT"): Promise<string[][]>;
function resolve(
hostname: string,
rrtype: string,
): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
/**

@@ -349,3 +352,3 @@ * Uses the DNS protocol to resolve IPv4 addresses (`A` records) for the`hostname`. On success, the `Promise` is resolved with an array of IPv4

*/
function setDefaultResultOrder(order: 'ipv4first' | 'verbatim'): void;
function setDefaultResultOrder(order: "ipv4first" | "verbatim"): void;
class Resolver {

@@ -372,4 +375,4 @@ constructor(options?: ResolverOptions);

}
declare module 'node:dns/promises' {
export * from 'dns/promises';
declare module "node:dns/promises" {
export * from "dns/promises";
}

@@ -11,68 +11,66 @@ export {}; // Don't export anything!

// the copy below in a Node environment.
type __Event = typeof globalThis extends { onmessage: any, Event: any }
? {}
: {
/** This is not used in Node.js and is provided purely for completeness. */
readonly bubbles: boolean;
/** Alias for event.stopPropagation(). This is not used in Node.js and is provided purely for completeness. */
cancelBubble: () => void;
/** True if the event was created with the cancelable option */
readonly cancelable: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly composed: boolean;
/** Returns an array containing the current EventTarget as the only entry or empty if the event is not being dispatched. This is not used in Node.js and is provided purely for completeness. */
composedPath(): [EventTarget?]
/** Alias for event.target. */
readonly currentTarget: EventTarget | null;
/** Is true if cancelable is true and event.preventDefault() has been called. */
readonly defaultPrevented: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly eventPhase: 0 | 2;
/** The `AbortSignal` "abort" event is emitted with `isTrusted` set to `true`. The value is `false` in all other cases. */
readonly isTrusted: boolean;
/** Sets the `defaultPrevented` property to `true` if `cancelable` is `true`. */
preventDefault(): void;
/** This is not used in Node.js and is provided purely for completeness. */
returnValue: boolean;
/** Alias for event.target. */
readonly srcElement: EventTarget | null;
/** Stops the invocation of event listeners after the current one completes. */
stopImmediatePropagation(): void;
/** This is not used in Node.js and is provided purely for completeness. */
stopPropagation(): void;
/** The `EventTarget` dispatching the event */
readonly target: EventTarget | null;
/** The millisecond timestamp when the Event object was created. */
readonly timeStamp: number;
/** Returns the type of event, e.g. "click", "hashchange", or "submit". */
readonly type: string;
};
type __Event = typeof globalThis extends { onmessage: any; Event: any } ? {}
: {
/** This is not used in Node.js and is provided purely for completeness. */
readonly bubbles: boolean;
/** Alias for event.stopPropagation(). This is not used in Node.js and is provided purely for completeness. */
cancelBubble: () => void;
/** True if the event was created with the cancelable option */
readonly cancelable: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly composed: boolean;
/** Returns an array containing the current EventTarget as the only entry or empty if the event is not being dispatched. This is not used in Node.js and is provided purely for completeness. */
composedPath(): [EventTarget?];
/** Alias for event.target. */
readonly currentTarget: EventTarget | null;
/** Is true if cancelable is true and event.preventDefault() has been called. */
readonly defaultPrevented: boolean;
/** This is not used in Node.js and is provided purely for completeness. */
readonly eventPhase: 0 | 2;
/** The `AbortSignal` "abort" event is emitted with `isTrusted` set to `true`. The value is `false` in all other cases. */
readonly isTrusted: boolean;
/** Sets the `defaultPrevented` property to `true` if `cancelable` is `true`. */
preventDefault(): void;
/** This is not used in Node.js and is provided purely for completeness. */
returnValue: boolean;
/** Alias for event.target. */
readonly srcElement: EventTarget | null;
/** Stops the invocation of event listeners after the current one completes. */
stopImmediatePropagation(): void;
/** This is not used in Node.js and is provided purely for completeness. */
stopPropagation(): void;
/** The `EventTarget` dispatching the event */
readonly target: EventTarget | null;
/** The millisecond timestamp when the Event object was created. */
readonly timeStamp: number;
/** Returns the type of event, e.g. "click", "hashchange", or "submit". */
readonly type: string;
};
// See comment above explaining conditional type
type __EventTarget = typeof globalThis extends { onmessage: any, EventTarget: any }
? {}
: {
/**
* Adds a new handler for the `type` event. Any given `listener` is added only once per `type` and per `capture` option value.
*
* If the `once` option is true, the `listener` is removed after the next time a `type` event is dispatched.
*
* The `capture` option is not used by Node.js in any functional way other than tracking registered event listeners per the `EventTarget` specification.
* Specifically, the `capture` option is used as part of the key when registering a `listener`.
* Any individual `listener` may be added once with `capture = false`, and once with `capture = true`.
*/
addEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: AddEventListenerOptions | boolean,
): void;
/** Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise. */
dispatchEvent(event: Event): boolean;
/** Removes the event listener in target's event listener list with the same type, callback, and options. */
removeEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: EventListenerOptions | boolean,
): void;
};
type __EventTarget = typeof globalThis extends { onmessage: any; EventTarget: any } ? {}
: {
/**
* Adds a new handler for the `type` event. Any given `listener` is added only once per `type` and per `capture` option value.
*
* If the `once` option is true, the `listener` is removed after the next time a `type` event is dispatched.
*
* The `capture` option is not used by Node.js in any functional way other than tracking registered event listeners per the `EventTarget` specification.
* Specifically, the `capture` option is used as part of the key when registering a `listener`.
* Any individual `listener` may be added once with `capture = false`, and once with `capture = true`.
*/
addEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: AddEventListenerOptions | boolean,
): void;
/** Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise. */
dispatchEvent(event: Event): boolean;
/** Removes the event listener in target's event listener list with the same type, callback, and options. */
removeEventListener(
type: string,
listener: EventListener | EventListenerObject,
options?: EventListenerOptions | boolean,
): void;
};

@@ -105,11 +103,10 @@ interface EventInit {

import {} from 'events'; // Make this an ambient declaration
import {} from "events"; // Make this an ambient declaration
declare global {
/** An event which takes place in the DOM. */
interface Event extends __Event {}
var Event: typeof globalThis extends { onmessage: any, Event: infer T }
? T
var Event: typeof globalThis extends { onmessage: any; Event: infer T } ? T
: {
prototype: __Event;
new (type: string, eventInitDict?: EventInit): __Event;
new(type: string, eventInitDict?: EventInit): __Event;
};

@@ -122,8 +119,7 @@

interface EventTarget extends __EventTarget {}
var EventTarget: typeof globalThis extends { onmessage: any, EventTarget: infer T }
? T
var EventTarget: typeof globalThis extends { onmessage: any; EventTarget: infer T } ? T
: {
prototype: __EventTarget;
new (): __EventTarget;
new(): __EventTarget;
};
}

@@ -17,4 +17,4 @@ /**

*/
declare module 'domain' {
import EventEmitter = require('node:events');
declare module "domain" {
import EventEmitter = require("node:events");
/**

@@ -169,4 +169,4 @@ * The `Domain` class encapsulates the functionality of routing errors and

}
declare module 'node:domain' {
export * from 'domain';
declare module "node:domain" {
export * from "domain";
}

@@ -37,3 +37,3 @@ /**

*/
declare module 'events' {
declare module "events" {
// NOTE: This class is in the docs but is **not actually exported** by Node.

@@ -91,3 +91,3 @@ // If https://github.com/nodejs/node/issues/39903 gets resolved and Node

once: boolean;
}
},
): any;

@@ -196,3 +196,7 @@ }

*/
static once(emitter: _NodeEventTarget, eventName: string | symbol, options?: StaticEventEmitterOptions): Promise<any[]>;
static once(
emitter: _NodeEventTarget,
eventName: string | symbol,
options?: StaticEventEmitterOptions,
): Promise<any[]>;
static once(emitter: _DOMEventTarget, eventName: string, options?: StaticEventEmitterOptions): Promise<any[]>;

@@ -257,3 +261,7 @@ /**

*/
static on(emitter: NodeJS.EventEmitter, eventName: string, options?: StaticEventEmitterOptions): AsyncIterableIterator<any>;
static on(
emitter: NodeJS.EventEmitter,
eventName: string,
options?: StaticEventEmitterOptions,
): AsyncIterableIterator<any>;
/**

@@ -369,3 +377,3 @@ * A class method that returns the number of listeners for the given `eventName`registered on the given `emitter`.

}
import internal = require('node:events');
import internal = require("node:events");
namespace EventEmitter {

@@ -713,5 +721,5 @@ // Should just be `export { EventEmitter }`, but that doesn't work in TypeScript 3.4

}
declare module 'node:events' {
import events = require('events');
declare module "node:events" {
import events = require("events");
export = events;
}

@@ -11,6 +11,6 @@ /**

*/
declare module 'fs/promises' {
import { Abortable } from 'node:events';
import { Stream } from 'node:stream';
import { ReadableStream } from 'node:stream/web';
declare module "fs/promises" {
import { Abortable } from "node:events";
import { Stream } from "node:stream";
import { ReadableStream } from "node:stream/web";
import {

@@ -34,4 +34,4 @@ BigIntStats,

RmOptions,
StatFsOptions,
StatOptions,
StatFsOptions,
Stats,

@@ -44,4 +44,4 @@ StatsFs,

WriteVResult,
} from 'node:fs';
import { Interface as ReadlineInterface } from 'node:readline';
} from "node:fs";
import { Interface as ReadlineInterface } from "node:readline";

@@ -95,3 +95,3 @@ interface FileChangeInfo<T extends string | Buffer> {

*/
type?: 'bytes' | undefined;
type?: "bytes" | undefined;
}

@@ -113,3 +113,6 @@ // TODO: Add `EventEmitter` close

*/
appendFile(data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null): Promise<void>;
appendFile(
data: string | Uint8Array,
options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null,
): Promise<void>;
/**

@@ -231,3 +234,8 @@ * Changes the ownership of the file. A wrapper for [`chown(2)`](http://man7.org/linux/man-pages/man2/chown.2.html).

*/
read<T extends NodeJS.ArrayBufferView>(buffer: T, offset?: number | null, length?: number | null, position?: number | null): Promise<FileReadResult<T>>;
read<T extends NodeJS.ArrayBufferView>(
buffer: T,
offset?: number | null,
length?: number | null,
position?: number | null,
): Promise<FileReadResult<T>>;
read<T extends NodeJS.ArrayBufferView = Buffer>(options?: FileReadOptions<T>): Promise<FileReadResult<T>>;

@@ -275,3 +283,3 @@ /**

flag?: OpenMode | undefined;
} | null
} | null,
): Promise<Buffer>;

@@ -287,6 +295,6 @@ /**

| {
encoding: BufferEncoding;
flag?: OpenMode | undefined;
}
| BufferEncoding
encoding: BufferEncoding;
flag?: OpenMode | undefined;
}
| BufferEncoding,
): Promise<string>;

@@ -302,6 +310,6 @@ /**

| (ObjectEncodingOptions & {
flag?: OpenMode | undefined;
})
flag?: OpenMode | undefined;
})
| BufferEncoding
| null
| null,
): Promise<string | Buffer>;

@@ -332,3 +340,3 @@ /**

bigint?: false | undefined;
}
},
): Promise<Stats>;

@@ -338,3 +346,3 @@ stat(

bigint: true;
}
},
): Promise<BigIntStats>;

@@ -394,3 +402,6 @@ stat(opts?: StatOptions): Promise<Stats | BigIntStats>;

*/
writeFile(data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode & Abortable) | BufferEncoding | null): Promise<void>;
writeFile(
data: string | Uint8Array,
options?: (ObjectEncodingOptions & FlagAndOpenMode & Abortable) | BufferEncoding | null,
): Promise<void>;
/**

@@ -418,3 +429,3 @@ * Write `buffer` to the file.

length?: number | null,
position?: number | null
position?: number | null,
): Promise<{

@@ -427,3 +438,3 @@ bytesWritten: number;

position?: number | null,
encoding?: BufferEncoding | null
encoding?: BufferEncoding | null,
): Promise<{

@@ -605,3 +616,3 @@ bytesWritten: number;

recursive: true;
}
},
): Promise<string | undefined>;

@@ -619,5 +630,5 @@ /**

| (MakeDirectoryOptions & {
recursive?: false | undefined;
})
| null
recursive?: false | undefined;
})
| null,
): Promise<void>;

@@ -659,7 +670,7 @@ /**

| (ObjectEncodingOptions & {
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
| BufferEncoding
| null
| null,
): Promise<string[]>;

@@ -675,7 +686,7 @@ /**

| {
encoding: 'buffer';
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
}
| 'buffer'
encoding: "buffer";
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
}
| "buffer",
): Promise<Buffer[]>;

@@ -691,7 +702,7 @@ /**

| (ObjectEncodingOptions & {
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
withFileTypes?: false | undefined;
recursive?: boolean | undefined;
})
| BufferEncoding
| null
| null,
): Promise<string[] | Buffer[]>;

@@ -708,3 +719,3 @@ /**

recursive?: boolean | undefined;
}
},
): Promise<Dirent[]>;

@@ -757,3 +768,3 @@ /**

bigint?: false | undefined;
}
},
): Promise<Stats>;

@@ -764,3 +775,3 @@ function lstat(

bigint: true;
}
},
): Promise<BigIntStats>;

@@ -776,3 +787,3 @@ function lstat(path: PathLike, opts?: StatOptions): Promise<Stats | BigIntStats>;

bigint?: false | undefined;
}
},
): Promise<Stats>;

@@ -783,3 +794,3 @@ function stat(

bigint: true;
}
},
): Promise<BigIntStats>;

@@ -795,3 +806,3 @@ function stat(path: PathLike, opts?: StatOptions): Promise<Stats | BigIntStats>;

bigint?: false | undefined;
}
},
): Promise<StatsFs>;

@@ -802,3 +813,3 @@ function statfs(

bigint: true;
}
},
): Promise<BigIntStatsFs>;

@@ -895,3 +906,6 @@ function statfs(path: PathLike, opts?: StatFsOptions): Promise<StatsFs | BigIntStatsFs>;

*/
function realpath(path: PathLike, options?: ObjectEncodingOptions | BufferEncoding | null): Promise<string | Buffer>;
function realpath(
path: PathLike,
options?: ObjectEncodingOptions | BufferEncoding | null,
): Promise<string | Buffer>;
/**

@@ -989,10 +1003,15 @@ * Creates a unique temporary directory. A unique directory name is generated by

file: PathLike | FileHandle,
data: string | NodeJS.ArrayBufferView | Iterable<string | NodeJS.ArrayBufferView> | AsyncIterable<string | NodeJS.ArrayBufferView> | Stream,
data:
| string
| NodeJS.ArrayBufferView
| Iterable<string | NodeJS.ArrayBufferView>
| AsyncIterable<string | NodeJS.ArrayBufferView>
| Stream,
options?:
| (ObjectEncodingOptions & {
mode?: Mode | undefined;
flag?: OpenMode | undefined;
} & Abortable)
mode?: Mode | undefined;
flag?: OpenMode | undefined;
} & Abortable)
| BufferEncoding
| null
| null,
): Promise<void>;

@@ -1013,3 +1032,7 @@ /**

*/
function appendFile(path: PathLike | FileHandle, data: string | Uint8Array, options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null): Promise<void>;
function appendFile(
path: PathLike | FileHandle,
data: string | Uint8Array,
options?: (ObjectEncodingOptions & FlagAndOpenMode) | BufferEncoding | null,
): Promise<void>;
/**

@@ -1061,6 +1084,6 @@ * Asynchronously reads the entire contents of a file.

| ({
encoding?: null | undefined;
flag?: OpenMode | undefined;
} & Abortable)
| null
encoding?: null | undefined;
flag?: OpenMode | undefined;
} & Abortable)
| null,
): Promise<Buffer>;

@@ -1078,6 +1101,6 @@ /**

| ({
encoding: BufferEncoding;
flag?: OpenMode | undefined;
} & Abortable)
| BufferEncoding
encoding: BufferEncoding;
flag?: OpenMode | undefined;
} & Abortable)
| BufferEncoding,
): Promise<string>;

@@ -1094,8 +1117,11 @@ /**

options?:
| (ObjectEncodingOptions &
Abortable & {
flag?: OpenMode | undefined;
})
| (
& ObjectEncodingOptions
& Abortable
& {
flag?: OpenMode | undefined;
}
)
| BufferEncoding
| null
| null,
): Promise<string | Buffer>;

@@ -1165,5 +1191,5 @@ /**

| (WatchOptions & {
encoding: 'buffer';
})
| 'buffer'
encoding: "buffer";
})
| "buffer",
): AsyncIterable<FileChangeInfo<Buffer>>;

@@ -1187,3 +1213,6 @@ /**

*/
function watch(filename: PathLike, options: WatchOptions | string): AsyncIterable<FileChangeInfo<string>> | AsyncIterable<FileChangeInfo<Buffer>>;
function watch(
filename: PathLike,
options: WatchOptions | string,
): AsyncIterable<FileChangeInfo<string>> | AsyncIterable<FileChangeInfo<Buffer>>;
/**

@@ -1203,4 +1232,4 @@ * Asynchronously copies the entire directory structure from `src` to `dest`,

}
declare module 'node:fs/promises' {
export * from 'fs/promises';
declare module "node:fs/promises" {
export * from "fs/promises";
}

@@ -23,5 +23,5 @@ // Declare "static" methods in Error

// For backwards compability
interface NodeRequire extends NodeJS.Require { }
interface RequireResolve extends NodeJS.RequireResolve { }
interface NodeModule extends NodeJS.Module { }
interface NodeRequire extends NodeJS.Require {}
interface RequireResolve extends NodeJS.RequireResolve {}
interface NodeModule extends NodeJS.Module {}

@@ -45,15 +45,15 @@ declare var process: NodeJS.Process;

//#region borrowed
// #region borrowed
// from https://github.com/microsoft/TypeScript/blob/38da7c600c83e7b31193a62495239a0fe478cb67/lib/lib.webworker.d.ts#L633 until moved to separate lib
/** A controller object that allows you to abort one or more DOM requests as and when desired. */
interface AbortController {
/**
* Returns the AbortSignal object associated with this object.
*/
/**
* Returns the AbortSignal object associated with this object.
*/
readonly signal: AbortSignal;
/**
* Invoking this method will set this object's AbortSignal's aborted flag and signal to any observers that the associated activity is to be aborted.
*/
abort(reason?: any): void;
readonly signal: AbortSignal;
/**
* Invoking this method will set this object's AbortSignal's aborted flag and signal to any observers that the associated activity is to be aborted.
*/
abort(reason?: any): void;
}

@@ -63,29 +63,27 @@

interface AbortSignal extends EventTarget {
/**
* Returns true if this AbortSignal's AbortController has signaled to abort, and false otherwise.
*/
readonly aborted: boolean;
readonly reason: any;
onabort: null | ((this: AbortSignal, event: Event) => any);
throwIfAborted(): void;
/**
* Returns true if this AbortSignal's AbortController has signaled to abort, and false otherwise.
*/
readonly aborted: boolean;
readonly reason: any;
onabort: null | ((this: AbortSignal, event: Event) => any);
throwIfAborted(): void;
}
declare var AbortController: typeof globalThis extends {onmessage: any; AbortController: infer T}
? T
: {
prototype: AbortController;
new(): AbortController;
};
declare var AbortController: typeof globalThis extends { onmessage: any; AbortController: infer T } ? T
: {
prototype: AbortController;
new(): AbortController;
};
declare var AbortSignal: typeof globalThis extends {onmessage: any; AbortSignal: infer T}
? T
: {
prototype: AbortSignal;
new(): AbortSignal;
abort(reason?: any): AbortSignal;
timeout(milliseconds: number): AbortSignal;
};
//#endregion borrowed
declare var AbortSignal: typeof globalThis extends { onmessage: any; AbortSignal: infer T } ? T
: {
prototype: AbortSignal;
new(): AbortSignal;
abort(reason?: any): AbortSignal;
timeout(milliseconds: number): AbortSignal;
};
// #endregion borrowed
//#region ArrayLike.at()
// #region ArrayLike.at()
interface RelativeIndexable<T> {

@@ -112,3 +110,3 @@ /**

interface BigUint64Array extends RelativeIndexable<bigint> {}
//#endregion ArrayLike.at() end
// #endregion ArrayLike.at() end

@@ -122,3 +120,3 @@ /**

value: T,
transfer?: { transfer: ReadonlyArray<import('worker_threads').TransferListItem> },
transfer?: { transfer: ReadonlyArray<import("worker_threads").TransferListItem> },
): T;

@@ -220,3 +218,3 @@

isPaused(): boolean;
pipe<T extends WritableStream>(destination: T, options?: { end?: boolean | undefined; }): T;
pipe<T extends WritableStream>(destination: T, options?: { end?: boolean | undefined }): T;
unpipe(destination?: WritableStream): this;

@@ -237,3 +235,3 @@ unshift(chunk: string | Uint8Array, encoding?: BufferEncoding): void;

interface ReadWriteStream extends ReadableStream, WritableStream { }
interface ReadWriteStream extends ReadableStream, WritableStream {}

@@ -271,3 +269,3 @@ interface RefCounted {

interface RequireResolve {
(id: string, options?: { paths?: string[] | undefined; }): string;
(id: string, options?: { paths?: string[] | undefined }): string;
paths(request: string): string[] | null;

@@ -277,5 +275,5 @@ }

interface RequireExtensions extends Dict<(m: Module, filename: string) => any> {
'.js': (m: Module, filename: string) => any;
'.json': (m: Module, filename: string) => any;
'.node': (m: Module, filename: string) => any;
".js": (m: Module, filename: string) => any;
".json": (m: Module, filename: string) => any;
".node": (m: Module, filename: string) => any;
}

@@ -282,0 +280,0 @@ interface Module {

@@ -6,7 +6,7 @@ /**

*/
declare module 'https' {
import { Duplex } from 'node:stream';
import * as tls from 'node:tls';
import * as http from 'node:http';
import { URL } from 'node:url';
declare module "https" {
import { Duplex } from "node:stream";
import * as tls from "node:tls";
import * as http from "node:http";
import { URL } from "node:url";
type ServerOptions<

@@ -16,4 +16,6 @@ Request extends typeof http.IncomingMessage = typeof http.IncomingMessage,

> = tls.SecureContextOptions & tls.TlsOptions & http.ServerOptions<Request, Response>;
type RequestOptions = http.RequestOptions &
tls.SecureContextOptions & {
type RequestOptions =
& http.RequestOptions
& tls.SecureContextOptions
& {
checkServerIdentity?: typeof tls.checkServerIdentity | undefined;

@@ -63,9 +65,9 @@ rejectUnauthorized?: boolean | undefined; // Defaults to true

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
addListener(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
addListener(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
addListener(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -78,27 +80,27 @@ certificate: Buffer,

addListener(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
addListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
addListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'connection', listener: (socket: Duplex) => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'listening', listener: () => void): this;
addListener(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
addListener(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
addListener(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
addListener(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
addListener(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "connection", listener: (socket: Duplex) => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "listening", listener: () => void): this;
addListener(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
addListener(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
addListener(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
addListener(
event: 'connect',
event: "connect",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
addListener(event: 'request', listener: http.RequestListener<Request, Response>): this;
addListener(event: "request", listener: http.RequestListener<Request, Response>): this;
addListener(
event: 'upgrade',
event: "upgrade",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
emit(event: string, ...args: any[]): boolean;
emit(event: 'keylog', line: Buffer, tlsSocket: tls.TLSSocket): boolean;
emit(event: "keylog", line: Buffer, tlsSocket: tls.TLSSocket): boolean;
emit(
event: 'newSession',
event: "newSession",
sessionId: Buffer,

@@ -109,3 +111,3 @@ sessionData: Buffer,

emit(
event: 'OCSPRequest',
event: "OCSPRequest",
certificate: Buffer,

@@ -115,11 +117,11 @@ issuer: Buffer,

): boolean;
emit(event: 'resumeSession', sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void): boolean;
emit(event: 'secureConnection', tlsSocket: tls.TLSSocket): boolean;
emit(event: 'tlsClientError', err: Error, tlsSocket: tls.TLSSocket): boolean;
emit(event: 'close'): boolean;
emit(event: 'connection', socket: Duplex): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'listening'): boolean;
emit(event: "resumeSession", sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void): boolean;
emit(event: "secureConnection", tlsSocket: tls.TLSSocket): boolean;
emit(event: "tlsClientError", err: Error, tlsSocket: tls.TLSSocket): boolean;
emit(event: "close"): boolean;
emit(event: "connection", socket: Duplex): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "listening"): boolean;
emit(
event: 'checkContinue',
event: "checkContinue",
req: InstanceType<Request>,

@@ -129,22 +131,22 @@ res: InstanceType<Response> & { req: InstanceType<Request> },

emit(
event: 'checkExpectation',
event: "checkExpectation",
req: InstanceType<Request>,
res: InstanceType<Response> & { req: InstanceType<Request> },
): boolean;
emit(event: 'clientError', err: Error, socket: Duplex): boolean;
emit(event: 'connect', req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
emit(event: "clientError", err: Error, socket: Duplex): boolean;
emit(event: "connect", req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
emit(
event: 'request',
event: "request",
req: InstanceType<Request>,
res: InstanceType<Response> & { req: InstanceType<Request> },
): boolean;
emit(event: 'upgrade', req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
emit(event: "upgrade", req: InstanceType<Request>, socket: Duplex, head: Buffer): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
on(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
on(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
on(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -157,25 +159,25 @@ certificate: Buffer,

on(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
on(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
on(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'connection', listener: (socket: Duplex) => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'listening', listener: () => void): this;
on(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
on(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
on(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
on(event: 'connect', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
on(event: 'request', listener: http.RequestListener<Request, Response>): this;
on(event: 'upgrade', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
on(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
on(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
on(event: "close", listener: () => void): this;
on(event: "connection", listener: (socket: Duplex) => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "listening", listener: () => void): this;
on(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
on(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
on(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
on(event: "connect", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
on(event: "request", listener: http.RequestListener<Request, Response>): this;
on(event: "upgrade", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
once(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
once(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
once(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -188,25 +190,25 @@ certificate: Buffer,

once(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
once(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
once(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'connection', listener: (socket: Duplex) => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'listening', listener: () => void): this;
once(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
once(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
once(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
once(event: 'connect', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: 'request', listener: http.RequestListener<Request, Response>): this;
once(event: 'upgrade', listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
once(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
once(event: "close", listener: () => void): this;
once(event: "connection", listener: (socket: Duplex) => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "listening", listener: () => void): this;
once(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
once(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
once(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
once(event: "connect", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
once(event: "request", listener: http.RequestListener<Request, Response>): this;
once(event: "upgrade", listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependListener(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
prependListener(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -219,31 +221,31 @@ certificate: Buffer,

prependListener(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
prependListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'connection', listener: (socket: Duplex) => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'listening', listener: () => void): this;
prependListener(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
prependListener(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
prependListener(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
prependListener(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "connection", listener: (socket: Duplex) => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "listening", listener: () => void): this;
prependListener(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
prependListener(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
prependListener(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
prependListener(
event: 'connect',
event: "connect",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
prependListener(event: 'request', listener: http.RequestListener<Request, Response>): this;
prependListener(event: "request", listener: http.RequestListener<Request, Response>): this;
prependListener(
event: 'upgrade',
event: "upgrade",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'keylog', listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: "keylog", listener: (line: Buffer, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(
event: 'newSession',
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: (err: Error, resp: Buffer) => void) => void,
): this;
prependOnceListener(
event: 'OCSPRequest',
event: "OCSPRequest",
listener: (

@@ -256,21 +258,21 @@ certificate: Buffer,

prependOnceListener(
event: 'resumeSession',
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error, sessionData: Buffer) => void) => void,
): this;
prependOnceListener(event: 'secureConnection', listener: (tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'connection', listener: (socket: Duplex) => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'listening', listener: () => void): this;
prependOnceListener(event: 'checkContinue', listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: 'checkExpectation', listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: 'clientError', listener: (err: Error, socket: Duplex) => void): this;
prependOnceListener(event: "secureConnection", listener: (tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: "tlsClientError", listener: (err: Error, tlsSocket: tls.TLSSocket) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "connection", listener: (socket: Duplex) => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "listening", listener: () => void): this;
prependOnceListener(event: "checkContinue", listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: "checkExpectation", listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: "clientError", listener: (err: Error, socket: Duplex) => void): this;
prependOnceListener(
event: 'connect',
event: "connect",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,
): this;
prependOnceListener(event: 'request', listener: http.RequestListener<Request, Response>): this;
prependOnceListener(event: "request", listener: http.RequestListener<Request, Response>): this;
prependOnceListener(
event: 'upgrade',
event: "upgrade",
listener: (req: InstanceType<Request>, socket: Duplex, head: Buffer) => void,

@@ -551,4 +553,4 @@ ): this;

}
declare module 'node:https' {
export * from 'https';
declare module "node:https" {
export * from "https";
}
/**
* @since v0.3.7
*/
declare module 'module' {
import { URL } from 'node:url';
import { MessagePort } from 'node:worker_threads';
declare module "module" {
import { URL } from "node:url";
import { MessagePort } from "node:worker_threads";
namespace Module {

@@ -85,3 +85,3 @@ /**

}
type ModuleFormat = 'builtin' | 'commonjs' | 'json' | 'module' | 'wasm';
type ModuleFormat = "builtin" | "commonjs" | "json" | "module" | "wasm";
type ModuleSource = string | ArrayBuffer | NodeJS.TypedArray;

@@ -144,3 +144,6 @@ interface GlobalPreloadContext {

context: ResolveHookContext,
nextResolve: (specifier: string, context?: ResolveHookContext) => ResolveFnOutput | Promise<ResolveFnOutput>
nextResolve: (
specifier: string,
context?: ResolveHookContext,
) => ResolveFnOutput | Promise<ResolveFnOutput>,
) => ResolveFnOutput | Promise<ResolveFnOutput>;

@@ -184,3 +187,3 @@ interface LoadHookContext {

context: LoadHookContext,
nextLoad: (url: string, context?: LoadHookContext) => LoadFnOutput | Promise<LoadFnOutput>
nextLoad: (url: string, context?: LoadHookContext) => LoadFnOutput | Promise<LoadFnOutput>,
) => LoadFnOutput | Promise<LoadFnOutput>;

@@ -218,5 +221,5 @@ }

}
declare module 'node:module' {
import module = require('module');
declare module "node:module" {
import module = require("module");
export = module;
}

@@ -15,7 +15,11 @@ /**

*/
declare module 'net' {
import * as stream from 'node:stream';
import { Abortable, EventEmitter } from 'node:events';
import * as dns from 'node:dns';
type LookupFunction = (hostname: string, options: dns.LookupOneOptions, callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void) => void;
declare module "net" {
import * as stream from "node:stream";
import { Abortable, EventEmitter } from "node:events";
import * as dns from "node:dns";
type LookupFunction = (
hostname: string,
options: dns.LookupOneOptions,
callback: (err: NodeJS.ErrnoException | null, address: string, family: number) => void,
) => void;
interface AddressInfo {

@@ -74,3 +78,3 @@ address: string;

type SocketConnectOpts = TcpSocketConnectOpts | IpcSocketConnectOpts;
type SocketReadyState = 'opening' | 'open' | 'readOnly' | 'writeOnly' | 'closed';
type SocketReadyState = "opening" | "open" | "readOnly" | "writeOnly" | "closed";
/**

@@ -354,61 +358,76 @@ * This class is an abstraction of a TCP socket or a streaming `IPC` endpoint

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: (hadError: boolean) => void): this;
addListener(event: 'connect', listener: () => void): this;
addListener(event: 'data', listener: (data: Buffer) => void): this;
addListener(event: 'drain', listener: () => void): this;
addListener(event: 'end', listener: () => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
addListener(event: 'ready', listener: () => void): this;
addListener(event: 'timeout', listener: () => void): this;
addListener(event: "close", listener: (hadError: boolean) => void): this;
addListener(event: "connect", listener: () => void): this;
addListener(event: "data", listener: (data: Buffer) => void): this;
addListener(event: "drain", listener: () => void): this;
addListener(event: "end", listener: () => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
addListener(event: "ready", listener: () => void): this;
addListener(event: "timeout", listener: () => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close', hadError: boolean): boolean;
emit(event: 'connect'): boolean;
emit(event: 'data', data: Buffer): boolean;
emit(event: 'drain'): boolean;
emit(event: 'end'): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'lookup', err: Error, address: string, family: string | number, host: string): boolean;
emit(event: 'ready'): boolean;
emit(event: 'timeout'): boolean;
emit(event: "close", hadError: boolean): boolean;
emit(event: "connect"): boolean;
emit(event: "data", data: Buffer): boolean;
emit(event: "drain"): boolean;
emit(event: "end"): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "lookup", err: Error, address: string, family: string | number, host: string): boolean;
emit(event: "ready"): boolean;
emit(event: "timeout"): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: (hadError: boolean) => void): this;
on(event: 'connect', listener: () => void): this;
on(event: 'data', listener: (data: Buffer) => void): this;
on(event: 'drain', listener: () => void): this;
on(event: 'end', listener: () => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
on(event: 'ready', listener: () => void): this;
on(event: 'timeout', listener: () => void): this;
on(event: "close", listener: (hadError: boolean) => void): this;
on(event: "connect", listener: () => void): this;
on(event: "data", listener: (data: Buffer) => void): this;
on(event: "drain", listener: () => void): this;
on(event: "end", listener: () => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
on(event: "ready", listener: () => void): this;
on(event: "timeout", listener: () => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: (hadError: boolean) => void): this;
once(event: 'connect', listener: () => void): this;
once(event: 'data', listener: (data: Buffer) => void): this;
once(event: 'drain', listener: () => void): this;
once(event: 'end', listener: () => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
once(event: 'ready', listener: () => void): this;
once(event: 'timeout', listener: () => void): this;
once(event: "close", listener: (hadError: boolean) => void): this;
once(event: "connect", listener: () => void): this;
once(event: "data", listener: (data: Buffer) => void): this;
once(event: "drain", listener: () => void): this;
once(event: "end", listener: () => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
once(event: "ready", listener: () => void): this;
once(event: "timeout", listener: () => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: (hadError: boolean) => void): this;
prependListener(event: 'connect', listener: () => void): this;
prependListener(event: 'data', listener: (data: Buffer) => void): this;
prependListener(event: 'drain', listener: () => void): this;
prependListener(event: 'end', listener: () => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
prependListener(event: 'ready', listener: () => void): this;
prependListener(event: 'timeout', listener: () => void): this;
prependListener(event: "close", listener: (hadError: boolean) => void): this;
prependListener(event: "connect", listener: () => void): this;
prependListener(event: "data", listener: (data: Buffer) => void): this;
prependListener(event: "drain", listener: () => void): this;
prependListener(event: "end", listener: () => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
prependListener(event: "ready", listener: () => void): this;
prependListener(event: "timeout", listener: () => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: (hadError: boolean) => void): this;
prependOnceListener(event: 'connect', listener: () => void): this;
prependOnceListener(event: 'data', listener: (data: Buffer) => void): this;
prependOnceListener(event: 'drain', listener: () => void): this;
prependOnceListener(event: 'end', listener: () => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'lookup', listener: (err: Error, address: string, family: string | number, host: string) => void): this;
prependOnceListener(event: 'ready', listener: () => void): this;
prependOnceListener(event: 'timeout', listener: () => void): this;
prependOnceListener(event: "close", listener: (hadError: boolean) => void): this;
prependOnceListener(event: "connect", listener: () => void): this;
prependOnceListener(event: "data", listener: (data: Buffer) => void): this;
prependOnceListener(event: "drain", listener: () => void): this;
prependOnceListener(event: "end", listener: () => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(
event: "lookup",
listener: (err: Error, address: string, family: string | number, host: string) => void,
): this;
prependOnceListener(event: "ready", listener: () => void): this;
prependOnceListener(event: "timeout", listener: () => void): this;
}

@@ -606,39 +625,39 @@ interface ListenOptions extends Abortable {

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'connection', listener: (socket: Socket) => void): this;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'listening', listener: () => void): this;
addListener(event: 'drop', listener: (data?: DropArgument) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "connection", listener: (socket: Socket) => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "listening", listener: () => void): this;
addListener(event: "drop", listener: (data?: DropArgument) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'connection', socket: Socket): boolean;
emit(event: 'error', err: Error): boolean;
emit(event: 'listening'): boolean;
emit(event: 'drop', data?: DropArgument): boolean;
emit(event: "close"): boolean;
emit(event: "connection", socket: Socket): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "listening"): boolean;
emit(event: "drop", data?: DropArgument): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'connection', listener: (socket: Socket) => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'listening', listener: () => void): this;
on(event: 'drop', listener: (data?: DropArgument) => void): this;
on(event: "close", listener: () => void): this;
on(event: "connection", listener: (socket: Socket) => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "listening", listener: () => void): this;
on(event: "drop", listener: (data?: DropArgument) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'connection', listener: (socket: Socket) => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'listening', listener: () => void): this;
once(event: 'drop', listener: (data?: DropArgument) => void): this;
once(event: "close", listener: () => void): this;
once(event: "connection", listener: (socket: Socket) => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "listening", listener: () => void): this;
once(event: "drop", listener: (data?: DropArgument) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'connection', listener: (socket: Socket) => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'listening', listener: () => void): this;
prependListener(event: 'drop', listener: (data?: DropArgument) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "connection", listener: (socket: Socket) => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "listening", listener: () => void): this;
prependListener(event: "drop", listener: (data?: DropArgument) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'connection', listener: (socket: Socket) => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'listening', listener: () => void): this;
prependOnceListener(event: 'drop', listener: (data?: DropArgument) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "connection", listener: (socket: Socket) => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "listening", listener: () => void): this;
prependOnceListener(event: "drop", listener: (data?: DropArgument) => void): this;
}
type IPVersion = 'ipv4' | 'ipv6';
type IPVersion = "ipv4" | "ipv6";
/**

@@ -885,4 +904,4 @@ * The `BlockList` object can be used with some network APIs to specify rules for

}
declare module 'node:net' {
export * from 'net';
declare module "node:net" {
export * from "net";
}

@@ -10,3 +10,3 @@ /**

*/
declare module 'os' {
declare module "os" {
interface CpuInfo {

@@ -31,7 +31,7 @@ model: string;

interface NetworkInterfaceInfoIPv4 extends NetworkInterfaceBase {
family: 'IPv4';
family: "IPv4";
scopeid?: undefined;
}
interface NetworkInterfaceInfoIPv6 extends NetworkInterfaceBase {
family: 'IPv6';
family: "IPv6";
scopeid: number;

@@ -239,3 +239,3 @@ }

*/
function userInfo(options: { encoding: 'buffer' }): UserInfo<Buffer>;
function userInfo(options: { encoding: "buffer" }): UserInfo<Buffer>;
function userInfo(options?: { encoding: BufferEncoding }): UserInfo<string>;

@@ -449,3 +449,3 @@ type SignalConstants = {

*/
function endianness(): 'BE' | 'LE';
function endianness(): "BE" | "LE";
/**

@@ -475,4 +475,4 @@ * Returns the scheduling priority for the process specified by `pid`. If `pid` is

}
declare module 'node:os' {
export * from 'os';
declare module "node:os" {
export * from "os";
}

@@ -1,7 +0,7 @@

declare module 'path/posix' {
import path = require('path');
declare module "path/posix" {
import path = require("path");
export = path;
}
declare module 'path/win32' {
import path = require('path');
declare module "path/win32" {
import path = require("path");
export = path;

@@ -18,3 +18,3 @@ }

*/
declare module 'path' {
declare module "path" {
namespace path {

@@ -141,7 +141,7 @@ /**

*/
readonly sep: '\\' | '/';
readonly sep: "\\" | "/";
/**
* The platform-specific file delimiter. ';' or ':'.
*/
readonly delimiter: ';' | ':';
readonly delimiter: ";" | ":";
/**

@@ -182,13 +182,13 @@ * Returns an object from a path string - the opposite of format().

}
declare module 'node:path' {
import path = require('path');
declare module "node:path" {
import path = require("path");
export = path;
}
declare module 'node:path/posix' {
import path = require('path/posix');
declare module "node:path/posix" {
import path = require("path/posix");
export = path;
}
declare module 'node:path/win32' {
import path = require('path/win32');
declare module "node:path/win32" {
import path = require("path/win32");
export = path;
}

@@ -31,5 +31,5 @@ /**

*/
declare module 'perf_hooks' {
import { AsyncResource } from 'node:async_hooks';
type EntryType = 'node' | 'mark' | 'measure' | 'gc' | 'function' | 'http2' | 'http';
declare module "perf_hooks" {
import { AsyncResource } from "node:async_hooks";
type EntryType = "node" | "mark" | "measure" | "gc" | "function" | "http2" | "http";
interface NodeGCPerformanceDetail {

@@ -93,6 +93,6 @@ /**

readonly duration: 0;
readonly entryType: 'mark';
readonly entryType: "mark";
}
class PerformanceMeasure extends PerformanceEntry {
readonly entryType: 'measure';
readonly entryType: "measure";
}

@@ -159,3 +159,6 @@ /**

*/
type EventLoopUtilityFunction = (util1?: EventLoopUtilization, util2?: EventLoopUtilization) => EventLoopUtilization;
type EventLoopUtilityFunction = (
util1?: EventLoopUtilization,
util2?: EventLoopUtilization,
) => EventLoopUtilization;
interface MarkOptions {

@@ -315,3 +318,2 @@ /**

*
*
* performance.clearMarks();

@@ -450,9 +452,9 @@ * performance.clearMeasures();

| {
entryTypes: ReadonlyArray<EntryType>;
buffered?: boolean | undefined;
}
entryTypes: ReadonlyArray<EntryType>;
buffered?: boolean | undefined;
}
| {
type: EntryType;
buffered?: boolean | undefined;
}
type: EntryType;
buffered?: boolean | undefined;
},
): void;

@@ -559,3 +561,3 @@ }

*/
add(other: RecordableHistogram): void;
add(other: RecordableHistogram): void;
}

@@ -614,3 +616,3 @@ /**

import { performance as _performance } from 'perf_hooks';
import { performance as _performance } from "perf_hooks";
global {

@@ -625,9 +627,8 @@ /**

performance: infer T;
}
? T
} ? T
: typeof _performance;
}
}
declare module 'node:perf_hooks' {
export * from 'perf_hooks';
declare module "node:perf_hooks" {
export * from "perf_hooks";
}

@@ -29,3 +29,3 @@ /**

*/
declare module 'punycode' {
declare module "punycode" {
/**

@@ -116,4 +116,4 @@ * The `punycode.decode()` method converts a [Punycode](https://tools.ietf.org/html/rfc3492) string of ASCII-only

}
declare module 'node:punycode' {
export * from 'punycode';
declare module "node:punycode" {
export * from "punycode";
}

@@ -14,3 +14,3 @@ /**

*/
declare module 'querystring' {
declare module "querystring" {
interface StringifyOptions {

@@ -24,3 +24,13 @@ encodeURIComponent?: ((str: string) => string) | undefined;

interface ParsedUrlQuery extends NodeJS.Dict<string | string[]> {}
interface ParsedUrlQueryInput extends NodeJS.Dict<string | number | boolean | ReadonlyArray<string> | ReadonlyArray<number> | ReadonlyArray<boolean> | null> {}
interface ParsedUrlQueryInput extends
NodeJS.Dict<
| string
| number
| boolean
| ReadonlyArray<string>
| ReadonlyArray<number>
| ReadonlyArray<boolean>
| null
>
{}
/**

@@ -131,4 +141,4 @@ * The `querystring.stringify()` method produces a URL query string from a

}
declare module 'node:querystring' {
export * from 'querystring';
declare module "node:querystring" {
export * from "querystring";
}

@@ -35,5 +35,5 @@ /**

*/
declare module 'readline' {
import { Abortable, EventEmitter } from 'node:events';
import * as promises from 'node:readline/promises';
declare module "readline" {
import { Abortable, EventEmitter } from "node:events";
import * as promises from "node:readline/promises";

@@ -106,3 +106,8 @@ export { promises };

*/
protected constructor(input: NodeJS.ReadableStream, output?: NodeJS.WritableStream, completer?: Completer | AsyncCompleter, terminal?: boolean);
protected constructor(
input: NodeJS.ReadableStream,
output?: NodeJS.WritableStream,
completer?: Completer | AsyncCompleter,
terminal?: boolean,
);
/**

@@ -268,55 +273,55 @@ * NOTE: According to the documentation:

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'line', listener: (input: string) => void): this;
addListener(event: 'pause', listener: () => void): this;
addListener(event: 'resume', listener: () => void): this;
addListener(event: 'SIGCONT', listener: () => void): this;
addListener(event: 'SIGINT', listener: () => void): this;
addListener(event: 'SIGTSTP', listener: () => void): this;
addListener(event: 'history', listener: (history: string[]) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "line", listener: (input: string) => void): this;
addListener(event: "pause", listener: () => void): this;
addListener(event: "resume", listener: () => void): this;
addListener(event: "SIGCONT", listener: () => void): this;
addListener(event: "SIGINT", listener: () => void): this;
addListener(event: "SIGTSTP", listener: () => void): this;
addListener(event: "history", listener: (history: string[]) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'line', input: string): boolean;
emit(event: 'pause'): boolean;
emit(event: 'resume'): boolean;
emit(event: 'SIGCONT'): boolean;
emit(event: 'SIGINT'): boolean;
emit(event: 'SIGTSTP'): boolean;
emit(event: 'history', history: string[]): boolean;
emit(event: "close"): boolean;
emit(event: "line", input: string): boolean;
emit(event: "pause"): boolean;
emit(event: "resume"): boolean;
emit(event: "SIGCONT"): boolean;
emit(event: "SIGINT"): boolean;
emit(event: "SIGTSTP"): boolean;
emit(event: "history", history: string[]): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'line', listener: (input: string) => void): this;
on(event: 'pause', listener: () => void): this;
on(event: 'resume', listener: () => void): this;
on(event: 'SIGCONT', listener: () => void): this;
on(event: 'SIGINT', listener: () => void): this;
on(event: 'SIGTSTP', listener: () => void): this;
on(event: 'history', listener: (history: string[]) => void): this;
on(event: "close", listener: () => void): this;
on(event: "line", listener: (input: string) => void): this;
on(event: "pause", listener: () => void): this;
on(event: "resume", listener: () => void): this;
on(event: "SIGCONT", listener: () => void): this;
on(event: "SIGINT", listener: () => void): this;
on(event: "SIGTSTP", listener: () => void): this;
on(event: "history", listener: (history: string[]) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'line', listener: (input: string) => void): this;
once(event: 'pause', listener: () => void): this;
once(event: 'resume', listener: () => void): this;
once(event: 'SIGCONT', listener: () => void): this;
once(event: 'SIGINT', listener: () => void): this;
once(event: 'SIGTSTP', listener: () => void): this;
once(event: 'history', listener: (history: string[]) => void): this;
once(event: "close", listener: () => void): this;
once(event: "line", listener: (input: string) => void): this;
once(event: "pause", listener: () => void): this;
once(event: "resume", listener: () => void): this;
once(event: "SIGCONT", listener: () => void): this;
once(event: "SIGINT", listener: () => void): this;
once(event: "SIGTSTP", listener: () => void): this;
once(event: "history", listener: (history: string[]) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'line', listener: (input: string) => void): this;
prependListener(event: 'pause', listener: () => void): this;
prependListener(event: 'resume', listener: () => void): this;
prependListener(event: 'SIGCONT', listener: () => void): this;
prependListener(event: 'SIGINT', listener: () => void): this;
prependListener(event: 'SIGTSTP', listener: () => void): this;
prependListener(event: 'history', listener: (history: string[]) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "line", listener: (input: string) => void): this;
prependListener(event: "pause", listener: () => void): this;
prependListener(event: "resume", listener: () => void): this;
prependListener(event: "SIGCONT", listener: () => void): this;
prependListener(event: "SIGINT", listener: () => void): this;
prependListener(event: "SIGTSTP", listener: () => void): this;
prependListener(event: "history", listener: (history: string[]) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'line', listener: (input: string) => void): this;
prependOnceListener(event: 'pause', listener: () => void): this;
prependOnceListener(event: 'resume', listener: () => void): this;
prependOnceListener(event: 'SIGCONT', listener: () => void): this;
prependOnceListener(event: 'SIGINT', listener: () => void): this;
prependOnceListener(event: 'SIGTSTP', listener: () => void): this;
prependOnceListener(event: 'history', listener: (history: string[]) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "line", listener: (input: string) => void): this;
prependOnceListener(event: "pause", listener: () => void): this;
prependOnceListener(event: "resume", listener: () => void): this;
prependOnceListener(event: "SIGCONT", listener: () => void): this;
prependOnceListener(event: "SIGINT", listener: () => void): this;
prependOnceListener(event: "SIGTSTP", listener: () => void): this;
prependOnceListener(event: "history", listener: (history: string[]) => void): this;
[Symbol.asyncIterator](): AsyncIterableIterator<string>;

@@ -326,3 +331,6 @@ }

export type Completer = (line: string) => CompleterResult;
export type AsyncCompleter = (line: string, callback: (err?: null | Error, result?: CompleterResult) => void) => void;
export type AsyncCompleter = (
line: string,
callback: (err?: null | Error, result?: CompleterResult) => void,
) => void;
export type CompleterResult = [string[], string];

@@ -390,3 +398,8 @@ export interface ReadLineOptions {

*/
export function createInterface(input: NodeJS.ReadableStream, output?: NodeJS.WritableStream, completer?: Completer | AsyncCompleter, terminal?: boolean): Interface;
export function createInterface(
input: NodeJS.ReadableStream,
output?: NodeJS.WritableStream,
completer?: Completer | AsyncCompleter,
terminal?: boolean,
): Interface;
export function createInterface(options: ReadLineOptions): Interface;

@@ -656,4 +669,4 @@ /**

}
declare module 'node:readline' {
export * from 'readline';
declare module "node:readline" {
export * from "readline";
}

@@ -7,5 +7,5 @@ /**

*/
declare module 'readline/promises' {
import { Interface as _Interface, ReadLineOptions, Completer, AsyncCompleter, Direction } from 'node:readline';
import { Abortable } from 'node:events';
declare module "readline/promises" {
import { AsyncCompleter, Completer, Direction, Interface as _Interface, ReadLineOptions } from "node:readline";
import { Abortable } from "node:events";

@@ -142,4 +142,4 @@ class Interface extends _Interface {

}
declare module 'node:readline/promises' {
export * from 'readline/promises';
declare module "node:readline/promises" {
export * from "readline/promises";
}

@@ -11,6 +11,6 @@ /**

*/
declare module 'repl' {
import { Interface, Completer, AsyncCompleter } from 'node:readline';
import { Context } from 'node:vm';
import { InspectOptions } from 'node:util';
declare module "repl" {
import { AsyncCompleter, Completer, Interface } from "node:readline";
import { Context } from "node:vm";
import { InspectOptions } from "node:util";
interface ReplOptions {

@@ -103,3 +103,9 @@ /**

}
type REPLEval = (this: REPLServer, evalCmd: string, context: Context, file: string, cb: (err: Error | null, result: any) => void) => void;
type REPLEval = (
this: REPLServer,
evalCmd: string,
context: Context,
file: string,
cb: (err: Error | null, result: any) => void,
) => void;
type REPLWriter = (this: REPLServer, obj: any) => string;

@@ -331,61 +337,61 @@ /**

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'line', listener: (input: string) => void): this;
addListener(event: 'pause', listener: () => void): this;
addListener(event: 'resume', listener: () => void): this;
addListener(event: 'SIGCONT', listener: () => void): this;
addListener(event: 'SIGINT', listener: () => void): this;
addListener(event: 'SIGTSTP', listener: () => void): this;
addListener(event: 'exit', listener: () => void): this;
addListener(event: 'reset', listener: (context: Context) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "line", listener: (input: string) => void): this;
addListener(event: "pause", listener: () => void): this;
addListener(event: "resume", listener: () => void): this;
addListener(event: "SIGCONT", listener: () => void): this;
addListener(event: "SIGINT", listener: () => void): this;
addListener(event: "SIGTSTP", listener: () => void): this;
addListener(event: "exit", listener: () => void): this;
addListener(event: "reset", listener: (context: Context) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'close'): boolean;
emit(event: 'line', input: string): boolean;
emit(event: 'pause'): boolean;
emit(event: 'resume'): boolean;
emit(event: 'SIGCONT'): boolean;
emit(event: 'SIGINT'): boolean;
emit(event: 'SIGTSTP'): boolean;
emit(event: 'exit'): boolean;
emit(event: 'reset', context: Context): boolean;
emit(event: "close"): boolean;
emit(event: "line", input: string): boolean;
emit(event: "pause"): boolean;
emit(event: "resume"): boolean;
emit(event: "SIGCONT"): boolean;
emit(event: "SIGINT"): boolean;
emit(event: "SIGTSTP"): boolean;
emit(event: "exit"): boolean;
emit(event: "reset", context: Context): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'close', listener: () => void): this;
on(event: 'line', listener: (input: string) => void): this;
on(event: 'pause', listener: () => void): this;
on(event: 'resume', listener: () => void): this;
on(event: 'SIGCONT', listener: () => void): this;
on(event: 'SIGINT', listener: () => void): this;
on(event: 'SIGTSTP', listener: () => void): this;
on(event: 'exit', listener: () => void): this;
on(event: 'reset', listener: (context: Context) => void): this;
on(event: "close", listener: () => void): this;
on(event: "line", listener: (input: string) => void): this;
on(event: "pause", listener: () => void): this;
on(event: "resume", listener: () => void): this;
on(event: "SIGCONT", listener: () => void): this;
on(event: "SIGINT", listener: () => void): this;
on(event: "SIGTSTP", listener: () => void): this;
on(event: "exit", listener: () => void): this;
on(event: "reset", listener: (context: Context) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'line', listener: (input: string) => void): this;
once(event: 'pause', listener: () => void): this;
once(event: 'resume', listener: () => void): this;
once(event: 'SIGCONT', listener: () => void): this;
once(event: 'SIGINT', listener: () => void): this;
once(event: 'SIGTSTP', listener: () => void): this;
once(event: 'exit', listener: () => void): this;
once(event: 'reset', listener: (context: Context) => void): this;
once(event: "close", listener: () => void): this;
once(event: "line", listener: (input: string) => void): this;
once(event: "pause", listener: () => void): this;
once(event: "resume", listener: () => void): this;
once(event: "SIGCONT", listener: () => void): this;
once(event: "SIGINT", listener: () => void): this;
once(event: "SIGTSTP", listener: () => void): this;
once(event: "exit", listener: () => void): this;
once(event: "reset", listener: (context: Context) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'line', listener: (input: string) => void): this;
prependListener(event: 'pause', listener: () => void): this;
prependListener(event: 'resume', listener: () => void): this;
prependListener(event: 'SIGCONT', listener: () => void): this;
prependListener(event: 'SIGINT', listener: () => void): this;
prependListener(event: 'SIGTSTP', listener: () => void): this;
prependListener(event: 'exit', listener: () => void): this;
prependListener(event: 'reset', listener: (context: Context) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "line", listener: (input: string) => void): this;
prependListener(event: "pause", listener: () => void): this;
prependListener(event: "resume", listener: () => void): this;
prependListener(event: "SIGCONT", listener: () => void): this;
prependListener(event: "SIGINT", listener: () => void): this;
prependListener(event: "SIGTSTP", listener: () => void): this;
prependListener(event: "exit", listener: () => void): this;
prependListener(event: "reset", listener: (context: Context) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'line', listener: (input: string) => void): this;
prependOnceListener(event: 'pause', listener: () => void): this;
prependOnceListener(event: 'resume', listener: () => void): this;
prependOnceListener(event: 'SIGCONT', listener: () => void): this;
prependOnceListener(event: 'SIGINT', listener: () => void): this;
prependOnceListener(event: 'SIGTSTP', listener: () => void): this;
prependOnceListener(event: 'exit', listener: () => void): this;
prependOnceListener(event: 'reset', listener: (context: Context) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "line", listener: (input: string) => void): this;
prependOnceListener(event: "pause", listener: () => void): this;
prependOnceListener(event: "resume", listener: () => void): this;
prependOnceListener(event: "SIGCONT", listener: () => void): this;
prependOnceListener(event: "SIGINT", listener: () => void): this;
prependOnceListener(event: "SIGTSTP", listener: () => void): this;
prependOnceListener(event: "exit", listener: () => void): this;
prependOnceListener(event: "reset", listener: (context: Context) => void): this;
}

@@ -425,4 +431,4 @@ /**

}
declare module 'node:repl' {
export * from 'repl';
declare module "node:repl" {
export * from "repl";
}

@@ -1,4 +0,4 @@

declare module 'stream/consumers' {
declare module "stream/consumers" {
import { Blob as NodeBlob } from "node:buffer";
import { Readable } from 'node:stream';
import { Readable } from "node:stream";
function buffer(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<Buffer>;

@@ -10,4 +10,4 @@ function text(stream: NodeJS.ReadableStream | Readable | AsyncIterator<any>): Promise<string>;

}
declare module 'node:stream/consumers' {
export * from 'stream/consumers';
declare module "node:stream/consumers" {
export * from "stream/consumers";
}

@@ -1,12 +0,35 @@

declare module 'stream/promises' {
import { FinishedOptions, PipelineSource, PipelineTransform, PipelineDestination, PipelinePromise, PipelineOptions } from 'node:stream';
function finished(stream: NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream, options?: FinishedOptions): Promise<void>;
function pipeline<A extends PipelineSource<any>, B extends PipelineDestination<A, any>>(source: A, destination: B, options?: PipelineOptions): PipelinePromise<B>;
function pipeline<A extends PipelineSource<any>, T1 extends PipelineTransform<A, any>, B extends PipelineDestination<T1, any>>(
declare module "stream/promises" {
import {
FinishedOptions,
PipelineDestination,
PipelineOptions,
PipelinePromise,
PipelineSource,
PipelineTransform,
} from "node:stream";
function finished(
stream: NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream,
options?: FinishedOptions,
): Promise<void>;
function pipeline<A extends PipelineSource<any>, B extends PipelineDestination<A, any>>(
source: A,
destination: B,
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline<
A extends PipelineSource<any>,
T1 extends PipelineTransform<A, any>,
B extends PipelineDestination<T1, any>,
>(
source: A,
transform1: T1,
destination: B,
options?: PipelineOptions
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline<A extends PipelineSource<any>, T1 extends PipelineTransform<A, any>, T2 extends PipelineTransform<T1, any>, B extends PipelineDestination<T2, any>>(
function pipeline<
A extends PipelineSource<any>,
T1 extends PipelineTransform<A, any>,
T2 extends PipelineTransform<T1, any>,
B extends PipelineDestination<T2, any>,
>(
source: A,

@@ -16,3 +39,3 @@ transform1: T1,

destination: B,
options?: PipelineOptions
options?: PipelineOptions,
): PipelinePromise<B>;

@@ -24,4 +47,11 @@ function pipeline<

T3 extends PipelineTransform<T2, any>,
B extends PipelineDestination<T3, any>
>(source: A, transform1: T1, transform2: T2, transform3: T3, destination: B, options?: PipelineOptions): PipelinePromise<B>;
B extends PipelineDestination<T3, any>,
>(
source: A,
transform1: T1,
transform2: T2,
transform3: T3,
destination: B,
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline<

@@ -33,6 +63,17 @@ A extends PipelineSource<any>,

T4 extends PipelineTransform<T3, any>,
B extends PipelineDestination<T4, any>
>(source: A, transform1: T1, transform2: T2, transform3: T3, transform4: T4, destination: B, options?: PipelineOptions): PipelinePromise<B>;
function pipeline(streams: ReadonlyArray<NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream>, options?: PipelineOptions): Promise<void>;
B extends PipelineDestination<T4, any>,
>(
source: A,
transform1: T1,
transform2: T2,
transform3: T3,
transform4: T4,
destination: B,
options?: PipelineOptions,
): PipelinePromise<B>;
function pipeline(
streams: ReadonlyArray<NodeJS.ReadableStream | NodeJS.WritableStream | NodeJS.ReadWriteStream>,
options?: PipelineOptions,
): Promise<void>;
function pipeline(
stream1: NodeJS.ReadableStream,

@@ -43,4 +84,4 @@ stream2: NodeJS.ReadWriteStream | NodeJS.WritableStream,

}
declare module 'node:stream/promises' {
export * from 'stream/promises';
declare module "node:stream/promises" {
export * from "stream/promises";
}

@@ -1,2 +0,2 @@

declare module 'stream/web' {
declare module "stream/web" {
// stub module, pending copy&paste from .d.ts or manual impl

@@ -77,3 +77,5 @@ // copy from lib.dom.d.ts

type ReadableStreamController<T> = ReadableStreamDefaultController<T>;
type ReadableStreamDefaultReadResult<T> = ReadableStreamDefaultReadValueResult<T> | ReadableStreamDefaultReadDoneResult;
type ReadableStreamDefaultReadResult<T> =
| ReadableStreamDefaultReadValueResult<T>
| ReadableStreamDefaultReadDoneResult;
interface ReadableByteStreamControllerCallback {

@@ -117,3 +119,3 @@ (controller: ReadableByteStreamController): void | PromiseLike<void>;

start?: ReadableByteStreamControllerCallback;
type: 'bytes';
type: "bytes";
}

@@ -149,4 +151,4 @@ interface UnderlyingSource<R = any> {

prototype: ReadableStream;
new (underlyingSource: UnderlyingByteSource, strategy?: QueuingStrategy<Uint8Array>): ReadableStream<Uint8Array>;
new <R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
new(underlyingSource: UnderlyingByteSource, strategy?: QueuingStrategy<Uint8Array>): ReadableStream<Uint8Array>;
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

@@ -159,3 +161,3 @@ interface ReadableStreamDefaultReader<R = any> extends ReadableStreamGenericReader {

prototype: ReadableStreamDefaultReader;
new <R = any>(stream: ReadableStream<R>): ReadableStreamDefaultReader<R>;
new<R = any>(stream: ReadableStream<R>): ReadableStreamDefaultReader<R>;
};

@@ -173,3 +175,3 @@ const ReadableStreamBYOBReader: any;

prototype: ReadableByteStreamController;
new (): ReadableByteStreamController;
new(): ReadableByteStreamController;
};

@@ -184,3 +186,3 @@ interface ReadableStreamDefaultController<R = any> {

prototype: ReadableStreamDefaultController;
new (): ReadableStreamDefaultController;
new(): ReadableStreamDefaultController;
};

@@ -200,3 +202,7 @@ interface Transformer<I = any, O = any> {

prototype: TransformStream;
new <I = any, O = any>(transformer?: Transformer<I, O>, writableStrategy?: QueuingStrategy<I>, readableStrategy?: QueuingStrategy<O>): TransformStream<I, O>;
new<I = any, O = any>(
transformer?: Transformer<I, O>,
writableStrategy?: QueuingStrategy<I>,
readableStrategy?: QueuingStrategy<O>,
): TransformStream<I, O>;
};

@@ -211,3 +217,3 @@ interface TransformStreamDefaultController<O = any> {

prototype: TransformStreamDefaultController;
new (): TransformStreamDefaultController;
new(): TransformStreamDefaultController;
};

@@ -227,3 +233,3 @@ /**

prototype: WritableStream;
new <W = any>(underlyingSink?: UnderlyingSink<W>, strategy?: QueuingStrategy<W>): WritableStream<W>;
new<W = any>(underlyingSink?: UnderlyingSink<W>, strategy?: QueuingStrategy<W>): WritableStream<W>;
};

@@ -247,3 +253,3 @@ /**

prototype: WritableStreamDefaultWriter;
new <W = any>(stream: WritableStream<W>): WritableStreamDefaultWriter<W>;
new<W = any>(stream: WritableStream<W>): WritableStreamDefaultWriter<W>;
};

@@ -261,3 +267,3 @@ /**

prototype: WritableStreamDefaultController;
new (): WritableStreamDefaultController;
new(): WritableStreamDefaultController;
};

@@ -293,3 +299,3 @@ interface QueuingStrategy<T = any> {

prototype: ByteLengthQueuingStrategy;
new (init: QueuingStrategyInit): ByteLengthQueuingStrategy;
new(init: QueuingStrategyInit): ByteLengthQueuingStrategy;
};

@@ -306,7 +312,7 @@ /**

prototype: CountQueuingStrategy;
new (init: QueuingStrategyInit): CountQueuingStrategy;
new(init: QueuingStrategyInit): CountQueuingStrategy;
};
interface TextEncoderStream {
/** Returns "utf-8". */
readonly encoding: 'utf-8';
readonly encoding: "utf-8";
readonly readable: ReadableStream<Uint8Array>;

@@ -318,3 +324,3 @@ readonly writable: WritableStream<string>;

prototype: TextEncoderStream;
new (): TextEncoderStream;
new(): TextEncoderStream;
};

@@ -339,7 +345,7 @@ interface TextDecoderOptions {

prototype: TextDecoderStream;
new (label?: string, options?: TextDecoderOptions): TextDecoderStream;
new(label?: string, options?: TextDecoderOptions): TextDecoderStream;
};
}
declare module 'node:stream/web' {
export * from 'stream/web';
declare module "node:stream/web" {
export * from "stream/web";
}

@@ -41,3 +41,3 @@ /**

*/
declare module 'string_decoder' {
declare module "string_decoder" {
class StringDecoder {

@@ -66,4 +66,4 @@ constructor(encoding?: BufferEncoding);

}
declare module 'node:string_decoder' {
export * from 'string_decoder';
declare module "node:string_decoder" {
export * from "string_decoder";
}

@@ -5,3 +5,3 @@ /**

*/
declare module 'node:test' {
declare module "node:test" {
/**

@@ -53,16 +53,3 @@ * Programmatically start the test runner.

namespace test {
export {
after,
afterEach,
before,
beforeEach,
describe,
it,
run,
mock,
test,
skip,
todo,
only
};
export { after, afterEach, before, beforeEach, describe, it, mock, only, run, skip, test, todo };
}

@@ -218,49 +205,49 @@ /**

interface TestsStream extends NodeJS.ReadableStream {
addListener(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
addListener(event: 'test:fail', listener: (data: TestFail) => void): this;
addListener(event: 'test:pass', listener: (data: TestPass) => void): this;
addListener(event: 'test:plan', listener: (data: TestPlan) => void): this;
addListener(event: 'test:start', listener: (data: TestStart) => void): this;
addListener(event: 'test:stderr', listener: (data: TestStderr) => void): this;
addListener(event: 'test:stdout', listener: (data: TestStdout) => void): this;
addListener(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
addListener(event: "test:fail", listener: (data: TestFail) => void): this;
addListener(event: "test:pass", listener: (data: TestPass) => void): this;
addListener(event: "test:plan", listener: (data: TestPlan) => void): this;
addListener(event: "test:start", listener: (data: TestStart) => void): this;
addListener(event: "test:stderr", listener: (data: TestStderr) => void): this;
addListener(event: "test:stdout", listener: (data: TestStdout) => void): this;
addListener(event: string, listener: (...args: any[]) => void): this;
emit(event: 'test:diagnostic', data: DiagnosticData): boolean;
emit(event: 'test:fail', data: TestFail): boolean;
emit(event: 'test:pass', data: TestPass): boolean;
emit(event: 'test:plan', data: TestPlan): boolean;
emit(event: 'test:start', data: TestStart): boolean;
emit(event: 'test:stderr', data: TestStderr): boolean;
emit(event: 'test:stdout', data: TestStdout): boolean;
emit(event: "test:diagnostic", data: DiagnosticData): boolean;
emit(event: "test:fail", data: TestFail): boolean;
emit(event: "test:pass", data: TestPass): boolean;
emit(event: "test:plan", data: TestPlan): boolean;
emit(event: "test:start", data: TestStart): boolean;
emit(event: "test:stderr", data: TestStderr): boolean;
emit(event: "test:stdout", data: TestStdout): boolean;
emit(event: string | symbol, ...args: any[]): boolean;
on(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
on(event: 'test:fail', listener: (data: TestFail) => void): this;
on(event: 'test:pass', listener: (data: TestPass) => void): this;
on(event: 'test:plan', listener: (data: TestPlan) => void): this;
on(event: 'test:start', listener: (data: TestStart) => void): this;
on(event: 'test:stderr', listener: (data: TestStderr) => void): this;
on(event: 'test:stdout', listener: (data: TestStdout) => void): this;
on(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
on(event: "test:fail", listener: (data: TestFail) => void): this;
on(event: "test:pass", listener: (data: TestPass) => void): this;
on(event: "test:plan", listener: (data: TestPlan) => void): this;
on(event: "test:start", listener: (data: TestStart) => void): this;
on(event: "test:stderr", listener: (data: TestStderr) => void): this;
on(event: "test:stdout", listener: (data: TestStdout) => void): this;
on(event: string, listener: (...args: any[]) => void): this;
once(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
once(event: 'test:fail', listener: (data: TestFail) => void): this;
once(event: 'test:pass', listener: (data: TestPass) => void): this;
once(event: 'test:plan', listener: (data: TestPlan) => void): this;
once(event: 'test:start', listener: (data: TestStart) => void): this;
once(event: 'test:stderr', listener: (data: TestStderr) => void): this;
once(event: 'test:stdout', listener: (data: TestStdout) => void): this;
once(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
once(event: "test:fail", listener: (data: TestFail) => void): this;
once(event: "test:pass", listener: (data: TestPass) => void): this;
once(event: "test:plan", listener: (data: TestPlan) => void): this;
once(event: "test:start", listener: (data: TestStart) => void): this;
once(event: "test:stderr", listener: (data: TestStderr) => void): this;
once(event: "test:stdout", listener: (data: TestStdout) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
prependListener(event: 'test:fail', listener: (data: TestFail) => void): this;
prependListener(event: 'test:pass', listener: (data: TestPass) => void): this;
prependListener(event: 'test:plan', listener: (data: TestPlan) => void): this;
prependListener(event: 'test:start', listener: (data: TestStart) => void): this;
prependListener(event: 'test:stderr', listener: (data: TestStderr) => void): this;
prependListener(event: 'test:stdout', listener: (data: TestStdout) => void): this;
prependListener(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
prependListener(event: "test:fail", listener: (data: TestFail) => void): this;
prependListener(event: "test:pass", listener: (data: TestPass) => void): this;
prependListener(event: "test:plan", listener: (data: TestPlan) => void): this;
prependListener(event: "test:start", listener: (data: TestStart) => void): this;
prependListener(event: "test:stderr", listener: (data: TestStderr) => void): this;
prependListener(event: "test:stdout", listener: (data: TestStdout) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'test:diagnostic', listener: (data: DiagnosticData) => void): this;
prependOnceListener(event: 'test:fail', listener: (data: TestFail) => void): this;
prependOnceListener(event: 'test:pass', listener: (data: TestPass) => void): this;
prependOnceListener(event: 'test:plan', listener: (data: TestPlan) => void): this;
prependOnceListener(event: 'test:start', listener: (data: TestStart) => void): this;
prependOnceListener(event: 'test:stderr', listener: (data: TestStderr) => void): this;
prependOnceListener(event: 'test:stdout', listener: (data: TestStdout) => void): this;
prependOnceListener(event: "test:diagnostic", listener: (data: DiagnosticData) => void): this;
prependOnceListener(event: "test:fail", listener: (data: TestFail) => void): this;
prependOnceListener(event: "test:pass", listener: (data: TestPass) => void): this;
prependOnceListener(event: "test:plan", listener: (data: TestPlan) => void): this;
prependOnceListener(event: "test:start", listener: (data: TestStart) => void): this;
prependOnceListener(event: "test:stderr", listener: (data: TestStderr) => void): this;
prependOnceListener(event: "test:stdout", listener: (data: TestStdout) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;

@@ -546,3 +533,7 @@ }

fn<F extends Function = NoOpFunction>(original?: F, options?: MockFunctionOptions): Mock<F>;
fn<F extends Function = NoOpFunction, Implementation extends Function = F>(original?: F, implementation?: Implementation, options?: MockFunctionOptions): Mock<F | Implementation>;
fn<F extends Function = NoOpFunction, Implementation extends Function = F>(
original?: F,
implementation?: Implementation,
options?: MockFunctionOptions,
): Mock<F | Implementation>;

@@ -563,4 +554,3 @@ /**

options?: MockFunctionOptions,
): MockedObject[MethodName] extends Function
? Mock<MockedObject[MethodName]>
): MockedObject[MethodName] extends Function ? Mock<MockedObject[MethodName]>
: never;

@@ -576,4 +566,3 @@ method<

options?: MockFunctionOptions,
): MockedObject[MethodName] extends Function
? Mock<MockedObject[MethodName] | Implementation>
): MockedObject[MethodName] extends Function ? Mock<MockedObject[MethodName] | Implementation>
: never;

@@ -657,12 +646,8 @@ method<MockedObject extends object>(

F extends Function,
ReturnType = F extends (...args: any) => infer T
? T
: F extends abstract new (...args: any) => infer T
? T
: unknown,
Args = F extends (...args: infer Y) => any
? Y
: F extends abstract new (...args: infer Y) => any
? Y
: unknown[],
ReturnType = F extends (...args: any) => infer T ? T
: F extends abstract new(...args: any) => infer T ? T
: unknown,
Args = F extends (...args: infer Y) => any ? Y
: F extends abstract new(...args: infer Y) => any ? Y
: unknown[],
> {

@@ -691,3 +676,3 @@ /**

*/
target: F extends abstract new (...args: any) => any ? F : undefined;
target: F extends abstract new(...args: any) => any ? F : undefined;
/**

@@ -740,3 +725,3 @@ * The mocked function's `this` value.

export { test as default, run, test, describe, it, before, after, beforeEach, afterEach, mock };
export { after, afterEach, before, beforeEach, describe, it, mock, run, test, test as default };
}

@@ -775,3 +760,3 @@

*/
type?: 'suite';
type?: "suite";
};

@@ -816,3 +801,3 @@ /**

*/
type?: 'suite';
type?: "suite";
};

@@ -938,16 +923,16 @@ /**

*/
declare module 'node:test/reporters' {
import { Transform } from 'node:stream';
declare module "node:test/reporters" {
import { Transform } from "node:stream";
type TestEvent =
| { type: 'test:diagnostic', data: DiagnosticData }
| { type: 'test:fail', data: TestFail }
| { type: 'test:pass', data: TestPass }
| { type: 'test:plan', data: TestPlan }
| { type: 'test:start', data: TestStart }
| { type: 'test:stderr', data: TestStderr }
| { type: 'test:stdout', data: TestStdout }
| { type: 'test:enqueue'; data: TestEnqueue }
| { type: 'test:dequeue'; data: TestDequeue }
| { type: 'test:watch:drained' };
| { type: "test:diagnostic"; data: DiagnosticData }
| { type: "test:fail"; data: TestFail }
| { type: "test:pass"; data: TestPass }
| { type: "test:plan"; data: TestPlan }
| { type: "test:start"; data: TestStart }
| { type: "test:stderr"; data: TestStderr }
| { type: "test:stdout"; data: TestStdout }
| { type: "test:enqueue"; data: TestEnqueue }
| { type: "test:dequeue"; data: TestDequeue }
| { type: "test:watch:drained" };
type TestEventGenerator = AsyncGenerator<TestEvent, void>;

@@ -960,3 +945,3 @@

*/
function dot(source: TestEventGenerator): AsyncGenerator<'\n' | '.' | 'X', void>;
function dot(source: TestEventGenerator): AsyncGenerator<"\n" | "." | "X", void>;
/**

@@ -972,3 +957,3 @@ * The `tap` reporter outputs the test results in the [TAP](https://testanything.org/) format.

}
export { dot, tap, Spec as spec, TestEvent };
export { dot, Spec as spec, tap, TestEvent };
}

@@ -11,5 +11,9 @@ /**

*/
declare module 'timers' {
import { Abortable } from 'node:events';
import { setTimeout as setTimeoutPromise, setImmediate as setImmediatePromise, setInterval as setIntervalPromise } from 'node:timers/promises';
declare module "timers" {
import { Abortable } from "node:events";
import {
setImmediate as setImmediatePromise,
setInterval as setIntervalPromise,
setTimeout as setTimeoutPromise,
} from "node:timers/promises";
interface TimerOptions extends Abortable {

@@ -66,3 +70,7 @@ /**

}
function setTimeout<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timeout;
function setTimeout<TArgs extends any[]>(
callback: (...args: TArgs) => void,
ms?: number,
...args: TArgs
): NodeJS.Timeout;
// util.promisify no rest args compability

@@ -75,3 +83,7 @@ // tslint:disable-next-line void-return

function clearTimeout(timeoutId: NodeJS.Timeout | string | number | undefined): void;
function setInterval<TArgs extends any[]>(callback: (...args: TArgs) => void, ms?: number, ...args: TArgs): NodeJS.Timer;
function setInterval<TArgs extends any[]>(
callback: (...args: TArgs) => void,
ms?: number,
...args: TArgs
): NodeJS.Timer;
// util.promisify no rest args compability

@@ -84,3 +96,6 @@ // tslint:disable-next-line void-return

function clearInterval(intervalId: NodeJS.Timeout | string | number | undefined): void;
function setImmediate<TArgs extends any[]>(callback: (...args: TArgs) => void, ...args: TArgs): NodeJS.Immediate;
function setImmediate<TArgs extends any[]>(
callback: (...args: TArgs) => void,
...args: TArgs
): NodeJS.Immediate;
// util.promisify no rest args compability

@@ -96,4 +111,4 @@ // tslint:disable-next-line void-return

}
declare module 'node:timers' {
export * from 'timers';
declare module "node:timers" {
export * from "timers";
}

@@ -14,4 +14,4 @@ /**

*/
declare module 'timers/promises' {
import { TimerOptions } from 'node:timers';
declare module "timers/promises" {
import { TimerOptions } from "node:timers";
/**

@@ -92,4 +92,4 @@ * ```js

}
declare module 'node:timers/promises' {
export * from 'timers/promises';
declare module "node:timers/promises" {
export * from "timers/promises";
}

@@ -11,6 +11,6 @@ /**

*/
declare module 'tls' {
import { X509Certificate } from 'node:crypto';
import * as net from 'node:net';
import * as stream from 'stream';
declare module "tls" {
import { X509Certificate } from "node:crypto";
import * as net from "node:net";
import * as stream from "stream";
const CLIENT_RENEG_LIMIT: number;

@@ -400,3 +400,3 @@ const CLIENT_RENEG_WINDOW: number;

},
callback: (err: Error | null) => void
callback: (err: Error | null) => void,
): undefined | boolean;

@@ -477,31 +477,31 @@ /**

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
addListener(event: 'secureConnect', listener: () => void): this;
addListener(event: 'session', listener: (session: Buffer) => void): this;
addListener(event: 'keylog', listener: (line: Buffer) => void): this;
addListener(event: "OCSPResponse", listener: (response: Buffer) => void): this;
addListener(event: "secureConnect", listener: () => void): this;
addListener(event: "session", listener: (session: Buffer) => void): this;
addListener(event: "keylog", listener: (line: Buffer) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'OCSPResponse', response: Buffer): boolean;
emit(event: 'secureConnect'): boolean;
emit(event: 'session', session: Buffer): boolean;
emit(event: 'keylog', line: Buffer): boolean;
emit(event: "OCSPResponse", response: Buffer): boolean;
emit(event: "secureConnect"): boolean;
emit(event: "session", session: Buffer): boolean;
emit(event: "keylog", line: Buffer): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
on(event: 'secureConnect', listener: () => void): this;
on(event: 'session', listener: (session: Buffer) => void): this;
on(event: 'keylog', listener: (line: Buffer) => void): this;
on(event: "OCSPResponse", listener: (response: Buffer) => void): this;
on(event: "secureConnect", listener: () => void): this;
on(event: "session", listener: (session: Buffer) => void): this;
on(event: "keylog", listener: (line: Buffer) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
once(event: 'secureConnect', listener: () => void): this;
once(event: 'session', listener: (session: Buffer) => void): this;
once(event: 'keylog', listener: (line: Buffer) => void): this;
once(event: "OCSPResponse", listener: (response: Buffer) => void): this;
once(event: "secureConnect", listener: () => void): this;
once(event: "session", listener: (session: Buffer) => void): this;
once(event: "keylog", listener: (line: Buffer) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
prependListener(event: 'secureConnect', listener: () => void): this;
prependListener(event: 'session', listener: (session: Buffer) => void): this;
prependListener(event: 'keylog', listener: (line: Buffer) => void): this;
prependListener(event: "OCSPResponse", listener: (response: Buffer) => void): this;
prependListener(event: "secureConnect", listener: () => void): this;
prependListener(event: "session", listener: (session: Buffer) => void): this;
prependListener(event: "keylog", listener: (line: Buffer) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'OCSPResponse', listener: (response: Buffer) => void): this;
prependOnceListener(event: 'secureConnect', listener: () => void): this;
prependOnceListener(event: 'session', listener: (session: Buffer) => void): this;
prependOnceListener(event: 'keylog', listener: (line: Buffer) => void): this;
prependOnceListener(event: "OCSPResponse", listener: (response: Buffer) => void): this;
prependOnceListener(event: "secureConnect", listener: () => void): this;
prependOnceListener(event: "session", listener: (session: Buffer) => void): this;
prependOnceListener(event: "keylog", listener: (line: Buffer) => void): this;
}

@@ -567,3 +567,2 @@ interface CommonConnectionOptions {

/**
*
* @param socket

@@ -683,43 +682,114 @@ * @param identity identity parameter sent from the client.

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
addListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
addListener(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
addListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
addListener(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
addListener(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
addListener(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
addListener(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
addListener(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
addListener(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
addListener(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
addListener(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'tlsClientError', err: Error, tlsSocket: TLSSocket): boolean;
emit(event: 'newSession', sessionId: Buffer, sessionData: Buffer, callback: () => void): boolean;
emit(event: 'OCSPRequest', certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void): boolean;
emit(event: 'resumeSession', sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void): boolean;
emit(event: 'secureConnection', tlsSocket: TLSSocket): boolean;
emit(event: 'keylog', line: Buffer, tlsSocket: TLSSocket): boolean;
emit(event: "tlsClientError", err: Error, tlsSocket: TLSSocket): boolean;
emit(event: "newSession", sessionId: Buffer, sessionData: Buffer, callback: () => void): boolean;
emit(
event: "OCSPRequest",
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
): boolean;
emit(
event: "resumeSession",
sessionId: Buffer,
callback: (err: Error | null, sessionData: Buffer | null) => void,
): boolean;
emit(event: "secureConnection", tlsSocket: TLSSocket): boolean;
emit(event: "keylog", line: Buffer, tlsSocket: TLSSocket): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
on(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
on(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
on(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
on(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
on(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
on(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
on(event: "newSession", listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
on(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
on(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
on(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
on(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
once(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
once(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
once(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
once(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
once(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
once(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
once(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
once(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
once(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
once(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
once(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
prependListener(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
prependListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
prependListener(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
prependListener(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependListener(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependListener(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
prependListener(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
prependListener(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
prependListener(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
prependListener(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'tlsClientError', listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: 'newSession', listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void): this;
prependOnceListener(event: 'OCSPRequest', listener: (certificate: Buffer, issuer: Buffer, callback: (err: Error | null, resp: Buffer) => void) => void): this;
prependOnceListener(event: 'resumeSession', listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void): this;
prependOnceListener(event: 'secureConnection', listener: (tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: 'keylog', listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: "tlsClientError", listener: (err: Error, tlsSocket: TLSSocket) => void): this;
prependOnceListener(
event: "newSession",
listener: (sessionId: Buffer, sessionData: Buffer, callback: () => void) => void,
): this;
prependOnceListener(
event: "OCSPRequest",
listener: (
certificate: Buffer,
issuer: Buffer,
callback: (err: Error | null, resp: Buffer) => void,
) => void,
): this;
prependOnceListener(
event: "resumeSession",
listener: (sessionId: Buffer, callback: (err: Error | null, sessionData: Buffer | null) => void) => void,
): this;
prependOnceListener(event: "secureConnection", listener: (tlsSocket: TLSSocket) => void): this;
prependOnceListener(event: "keylog", listener: (line: Buffer, tlsSocket: TLSSocket) => void): this;
}

@@ -733,3 +803,3 @@ /**

}
type SecureVersion = 'TLSv1.3' | 'TLSv1.2' | 'TLSv1.1' | 'TLSv1';
type SecureVersion = "TLSv1.3" | "TLSv1.2" | "TLSv1.1" | "TLSv1";
interface SecureContextOptions {

@@ -1005,3 +1075,8 @@ /**

function connect(options: ConnectionOptions, secureConnectListener?: () => void): TLSSocket;
function connect(port: number, host?: string, options?: ConnectionOptions, secureConnectListener?: () => void): TLSSocket;
function connect(
port: number,
host?: string,
options?: ConnectionOptions,
secureConnectListener?: () => void,
): TLSSocket;
function connect(port: number, options?: ConnectionOptions, secureConnectListener?: () => void): TLSSocket;

@@ -1041,3 +1116,8 @@ /**

*/
function createSecurePair(context?: SecureContext, isServer?: boolean, requestCert?: boolean, rejectUnauthorized?: boolean): SecurePair;
function createSecurePair(
context?: SecureContext,
isServer?: boolean,
requestCert?: boolean,
rejectUnauthorized?: boolean,
): SecurePair;
/**

@@ -1117,4 +1197,4 @@ * {@link createServer} sets the default value of the `honorCipherOrder` option

}
declare module 'node:tls' {
export * from 'tls';
declare module "node:tls" {
export * from "tls";
}

@@ -88,3 +88,3 @@ /**

*/
declare module 'trace_events' {
declare module "trace_events" {
/**

@@ -170,4 +170,4 @@ * The `Tracing` object is used to enable or disable tracing for sets of

}
declare module 'node:trace_events' {
export * from 'trace_events';
declare module "node:trace_events" {
export * from "trace_events";
}

@@ -27,4 +27,4 @@ /**

*/
declare module 'tty' {
import * as net from 'node:net';
declare module "tty" {
import * as net from "node:net";
/**

@@ -85,13 +85,13 @@ * The `tty.isatty()` method returns `true` if the given `fd` is associated with

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'resize', listener: () => void): this;
addListener(event: "resize", listener: () => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'resize'): boolean;
emit(event: "resize"): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'resize', listener: () => void): this;
on(event: "resize", listener: () => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'resize', listener: () => void): this;
once(event: "resize", listener: () => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'resize', listener: () => void): this;
prependListener(event: "resize", listener: () => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'resize', listener: () => void): this;
prependOnceListener(event: "resize", listener: () => void): this;
/**

@@ -206,4 +206,4 @@ * `writeStream.clearLine()` clears the current line of this `WriteStream` in a

}
declare module 'node:tty' {
export * from 'tty';
declare module "node:tty" {
export * from "tty";
}

@@ -10,6 +10,6 @@ /**

*/
declare module 'url' {
import { Blob as NodeBlob } from 'node:buffer';
import { ClientRequestArgs } from 'node:http';
import { ParsedUrlQuery, ParsedUrlQueryInput } from 'node:querystring';
declare module "url" {
import { Blob as NodeBlob } from "node:buffer";
import { ClientRequestArgs } from "node:http";
import { ParsedUrlQuery, ParsedUrlQueryInput } from "node:querystring";
// Input to `url.format`

@@ -76,3 +76,7 @@ interface UrlObject {

function parse(urlString: string): UrlWithStringQuery;
function parse(urlString: string, parseQueryString: false | undefined, slashesDenoteHost?: boolean): UrlWithStringQuery;
function parse(
urlString: string,
parseQueryString: false | undefined,
slashesDenoteHost?: boolean,
): UrlWithStringQuery;
function parse(urlString: string, parseQueryString: true, slashesDenoteHost?: boolean): UrlWithParsedQuery;

@@ -771,3 +775,10 @@ function parse(urlString: string, parseQueryString: boolean, slashesDenoteHost?: boolean): Url;

class URLSearchParams implements Iterable<[string, string]> {
constructor(init?: URLSearchParams | string | Record<string, string | ReadonlyArray<string>> | Iterable<[string, string]> | ReadonlyArray<[string, string]>);
constructor(
init?:
| URLSearchParams
| string
| Record<string, string | ReadonlyArray<string>>
| Iterable<[string, string]>
| ReadonlyArray<[string, string]>,
);
/**

@@ -803,3 +814,6 @@ * Append a new name-value pair to the query string.

*/
forEach<TThis = this>(callback: (this: TThis, value: string, name: string, searchParams: URLSearchParams) => void, thisArg?: TThis): void;
forEach<TThis = this>(
callback: (this: TThis, value: string, name: string, searchParams: URLSearchParams) => void,
thisArg?: TThis,
): void;
/**

@@ -886,3 +900,3 @@ * Returns the value of the first name-value pair whose name is `name`. If there

}
import { URL as _URL, URLSearchParams as _URLSearchParams } from 'url';
import { URL as _URL, URLSearchParams as _URLSearchParams } from "url";
global {

@@ -903,4 +917,3 @@ interface URLSearchParams extends _URLSearchParams {}

URL: infer T;
}
? T
} ? T
: typeof _URL;

@@ -915,9 +928,8 @@ /**

URLSearchParams: infer T;
}
? T
} ? T
: typeof _URLSearchParams;
}
}
declare module 'node:url' {
export * from 'url';
declare module "node:url" {
export * from "url";
}

@@ -9,4 +9,4 @@ /**

*/
declare module 'v8' {
import { Readable } from 'node:stream';
declare module "v8" {
import { Readable } from "node:stream";
interface HeapSpaceInfo {

@@ -540,4 +540,4 @@ space_name: string;

}
declare module 'node:v8' {
export * from 'v8';
declare module "node:v8" {
export * from "v8";
}

@@ -39,4 +39,4 @@ /**

*/
declare module 'vm' {
import { ImportAssertions } from 'node:module';
declare module "vm" {
import { ImportAssertions } from "node:module";
interface Context extends NodeJS.Dict<any> {}

@@ -71,3 +71,5 @@ interface BaseOptions {

*/
importModuleDynamically?: ((specifier: string, script: Script, importAssertions: ImportAssertions) => Module) | undefined;
importModuleDynamically?:
| ((specifier: string, script: Script, importAssertions: ImportAssertions) => Module)
| undefined;
}

@@ -97,3 +99,3 @@ interface RunningScriptOptions extends BaseOptions {

*/
contextName?: CreateContextOptions['name'];
contextName?: CreateContextOptions["name"];
/**

@@ -104,16 +106,16 @@ * Origin corresponding to the newly created context for display purposes. The origin should be formatted like a URL,

*/
contextOrigin?: CreateContextOptions['origin'];
contextCodeGeneration?: CreateContextOptions['codeGeneration'];
contextOrigin?: CreateContextOptions["origin"];
contextCodeGeneration?: CreateContextOptions["codeGeneration"];
/**
* If set to `afterEvaluate`, microtasks will be run immediately after the script has run.
*/
microtaskMode?: CreateContextOptions['microtaskMode'];
microtaskMode?: CreateContextOptions["microtaskMode"];
}
interface RunningCodeOptions extends RunningScriptOptions {
cachedData?: ScriptOptions['cachedData'];
importModuleDynamically?: ScriptOptions['importModuleDynamically'];
cachedData?: ScriptOptions["cachedData"];
importModuleDynamically?: ScriptOptions["importModuleDynamically"];
}
interface RunningCodeInNewContextOptions extends RunningScriptInNewContextOptions {
cachedData?: ScriptOptions['cachedData'];
importModuleDynamically?: ScriptOptions['importModuleDynamically'];
cachedData?: ScriptOptions["cachedData"];
importModuleDynamically?: ScriptOptions["importModuleDynamically"];
}

@@ -155,14 +157,14 @@ interface CompileFunctionOptions extends BaseOptions {

| {
/**
* If set to false any calls to eval or function constructors (Function, GeneratorFunction, etc)
* will throw an EvalError.
* @default true
*/
strings?: boolean | undefined;
/**
* If set to false any attempt to compile a WebAssembly module will throw a WebAssembly.CompileError.
* @default true
*/
wasm?: boolean | undefined;
}
/**
* If set to false any calls to eval or function constructors (Function, GeneratorFunction, etc)
* will throw an EvalError.
* @default true
*/
strings?: boolean | undefined;
/**
* If set to false any attempt to compile a WebAssembly module will throw a WebAssembly.CompileError.
* @default true
*/
wasm?: boolean | undefined;
}
| undefined;

@@ -172,5 +174,5 @@ /**

*/
microtaskMode?: 'afterEvaluate' | undefined;
microtaskMode?: "afterEvaluate" | undefined;
}
type MeasureMemoryMode = 'summary' | 'detailed';
type MeasureMemoryMode = "summary" | "detailed";
interface MeasureMemoryOptions {

@@ -184,3 +186,3 @@ /**

*/
execution?: 'default' | 'eager' | undefined;
execution?: "default" | "eager" | undefined;
}

@@ -419,3 +421,7 @@ interface MemoryMeasurement {

*/
function runInNewContext(code: string, contextObject?: Context, options?: RunningCodeInNewContextOptions | string): any;
function runInNewContext(
code: string,
contextObject?: Context,
options?: RunningCodeInNewContextOptions | string,
): any;
/**

@@ -492,6 +498,10 @@ * `vm.runInThisContext()` compiles `code`, runs it within the context of the

*/
function compileFunction(code: string, params?: ReadonlyArray<string>, options?: CompileFunctionOptions): Function & {
cachedData?: Script['cachedData'] | undefined;
cachedDataProduced?: Script['cachedDataProduced'] | undefined;
cachedDataRejected?: Script['cachedDataRejected'] | undefined;
function compileFunction(
code: string,
params?: ReadonlyArray<string>,
options?: CompileFunctionOptions,
): Function & {
cachedData?: Script["cachedData"] | undefined;
cachedDataProduced?: Script["cachedDataProduced"] | undefined;
cachedDataRejected?: Script["cachedDataRejected"] | undefined;
};

@@ -556,7 +566,11 @@ /**

interface ModuleEvaluateOptions {
timeout?: RunningScriptOptions['timeout'] | undefined;
breakOnSigint?: RunningScriptOptions['breakOnSigint'] | undefined;
timeout?: RunningScriptOptions["timeout"] | undefined;
breakOnSigint?: RunningScriptOptions["breakOnSigint"] | undefined;
}
type ModuleLinker = (specifier: string, referencingModule: Module, extra: { assert: Object }) => Module | Promise<Module>;
type ModuleStatus = 'unlinked' | 'linking' | 'linked' | 'evaluating' | 'evaluated' | 'errored';
type ModuleLinker = (
specifier: string,
referencingModule: Module,
extra: { assert: Object },
) => Module | Promise<Module>;
type ModuleStatus = "unlinked" | "linking" | "linked" | "evaluating" | "evaluated" | "errored";
class Module {

@@ -608,6 +622,6 @@ /**

identifier?: string | undefined;
cachedData?: ScriptOptions['cachedData'] | undefined;
cachedData?: ScriptOptions["cachedData"] | undefined;
context?: Context | undefined;
lineOffset?: BaseOptions['lineOffset'] | undefined;
columnOffset?: BaseOptions['columnOffset'] | undefined;
lineOffset?: BaseOptions["lineOffset"] | undefined;
columnOffset?: BaseOptions["columnOffset"] | undefined;
/**

@@ -617,3 +631,3 @@ * Called during evaluation of this module to initialize the `import.meta`.

initializeImportMeta?: ((meta: ImportMeta, module: SourceTextModule) => void) | undefined;
importModuleDynamically?: ScriptOptions['importModuleDynamically'] | undefined;
importModuleDynamically?: ScriptOptions["importModuleDynamically"] | undefined;
}

@@ -645,3 +659,7 @@ class SourceTextModule extends Module {

*/
constructor(exportNames: string[], evaluateCallback: (this: SyntheticModule) => void, options?: SyntheticModuleOptions);
constructor(
exportNames: string[],
evaluateCallback: (this: SyntheticModule) => void,
options?: SyntheticModuleOptions,
);
/**

@@ -656,4 +674,4 @@ * This method is used after the module is linked to set the values of exports.

}
declare module 'node:vm' {
export * from 'vm';
declare module "node:vm" {
export * from "vm";
}

@@ -73,3 +73,3 @@ /**

*/
declare module 'wasi' {
declare module "wasi" {
interface WASIOptions {

@@ -157,4 +157,4 @@ /**

}
declare module 'node:wasi' {
export * from 'wasi';
declare module "node:wasi" {
export * from "wasi";
}

@@ -54,11 +54,11 @@ /**

*/
declare module 'worker_threads' {
import { Blob } from 'node:buffer';
import { Context } from 'node:vm';
import { EventEmitter } from 'node:events';
import { EventLoopUtilityFunction } from 'node:perf_hooks';
import { FileHandle } from 'node:fs/promises';
import { Readable, Writable } from 'node:stream';
import { URL } from 'node:url';
import { X509Certificate } from 'node:crypto';
declare module "worker_threads" {
import { Blob } from "node:buffer";
import { Context } from "node:vm";
import { EventEmitter } from "node:events";
import { EventLoopUtilityFunction } from "node:perf_hooks";
import { FileHandle } from "node:fs/promises";
import { Readable, Writable } from "node:stream";
import { URL } from "node:url";
import { X509Certificate } from "node:crypto";
const isMainThread: boolean;

@@ -209,33 +209,33 @@ const parentPort: null | MessagePort;

start(): void;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'message', listener: (value: any) => void): this;
addListener(event: 'messageerror', listener: (error: Error) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "message", listener: (value: any) => void): this;
addListener(event: "messageerror", listener: (error: Error) => void): this;
addListener(event: string | symbol, listener: (...args: any[]) => void): this;
emit(event: 'close'): boolean;
emit(event: 'message', value: any): boolean;
emit(event: 'messageerror', error: Error): boolean;
emit(event: "close"): boolean;
emit(event: "message", value: any): boolean;
emit(event: "messageerror", error: Error): boolean;
emit(event: string | symbol, ...args: any[]): boolean;
on(event: 'close', listener: () => void): this;
on(event: 'message', listener: (value: any) => void): this;
on(event: 'messageerror', listener: (error: Error) => void): this;
on(event: "close", listener: () => void): this;
on(event: "message", listener: (value: any) => void): this;
on(event: "messageerror", listener: (error: Error) => void): this;
on(event: string | symbol, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'message', listener: (value: any) => void): this;
once(event: 'messageerror', listener: (error: Error) => void): this;
once(event: "close", listener: () => void): this;
once(event: "message", listener: (value: any) => void): this;
once(event: "messageerror", listener: (error: Error) => void): this;
once(event: string | symbol, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'message', listener: (value: any) => void): this;
prependListener(event: 'messageerror', listener: (error: Error) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "message", listener: (value: any) => void): this;
prependListener(event: "messageerror", listener: (error: Error) => void): this;
prependListener(event: string | symbol, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'message', listener: (value: any) => void): this;
prependOnceListener(event: 'messageerror', listener: (error: Error) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "message", listener: (value: any) => void): this;
prependOnceListener(event: "messageerror", listener: (error: Error) => void): this;
prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): this;
removeListener(event: 'close', listener: () => void): this;
removeListener(event: 'message', listener: (value: any) => void): this;
removeListener(event: 'messageerror', listener: (error: Error) => void): this;
removeListener(event: "close", listener: () => void): this;
removeListener(event: "message", listener: (value: any) => void): this;
removeListener(event: "messageerror", listener: (error: Error) => void): this;
removeListener(event: string | symbol, listener: (...args: any[]) => void): this;
off(event: 'close', listener: () => void): this;
off(event: 'message', listener: (value: any) => void): this;
off(event: 'messageerror', listener: (error: Error) => void): this;
off(event: "close", listener: () => void): this;
off(event: "message", listener: (value: any) => void): this;
off(event: "messageerror", listener: (error: Error) => void): this;
off(event: string | symbol, listener: (...args: any[]) => void): this;

@@ -439,49 +439,49 @@ }

getHeapSnapshot(): Promise<Readable>;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'exit', listener: (exitCode: number) => void): this;
addListener(event: 'message', listener: (value: any) => void): this;
addListener(event: 'messageerror', listener: (error: Error) => void): this;
addListener(event: 'online', listener: () => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "exit", listener: (exitCode: number) => void): this;
addListener(event: "message", listener: (value: any) => void): this;
addListener(event: "messageerror", listener: (error: Error) => void): this;
addListener(event: "online", listener: () => void): this;
addListener(event: string | symbol, listener: (...args: any[]) => void): this;
emit(event: 'error', err: Error): boolean;
emit(event: 'exit', exitCode: number): boolean;
emit(event: 'message', value: any): boolean;
emit(event: 'messageerror', error: Error): boolean;
emit(event: 'online'): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "exit", exitCode: number): boolean;
emit(event: "message", value: any): boolean;
emit(event: "messageerror", error: Error): boolean;
emit(event: "online"): boolean;
emit(event: string | symbol, ...args: any[]): boolean;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'exit', listener: (exitCode: number) => void): this;
on(event: 'message', listener: (value: any) => void): this;
on(event: 'messageerror', listener: (error: Error) => void): this;
on(event: 'online', listener: () => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "exit", listener: (exitCode: number) => void): this;
on(event: "message", listener: (value: any) => void): this;
on(event: "messageerror", listener: (error: Error) => void): this;
on(event: "online", listener: () => void): this;
on(event: string | symbol, listener: (...args: any[]) => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'exit', listener: (exitCode: number) => void): this;
once(event: 'message', listener: (value: any) => void): this;
once(event: 'messageerror', listener: (error: Error) => void): this;
once(event: 'online', listener: () => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "exit", listener: (exitCode: number) => void): this;
once(event: "message", listener: (value: any) => void): this;
once(event: "messageerror", listener: (error: Error) => void): this;
once(event: "online", listener: () => void): this;
once(event: string | symbol, listener: (...args: any[]) => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'exit', listener: (exitCode: number) => void): this;
prependListener(event: 'message', listener: (value: any) => void): this;
prependListener(event: 'messageerror', listener: (error: Error) => void): this;
prependListener(event: 'online', listener: () => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "exit", listener: (exitCode: number) => void): this;
prependListener(event: "message", listener: (value: any) => void): this;
prependListener(event: "messageerror", listener: (error: Error) => void): this;
prependListener(event: "online", listener: () => void): this;
prependListener(event: string | symbol, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'exit', listener: (exitCode: number) => void): this;
prependOnceListener(event: 'message', listener: (value: any) => void): this;
prependOnceListener(event: 'messageerror', listener: (error: Error) => void): this;
prependOnceListener(event: 'online', listener: () => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "exit", listener: (exitCode: number) => void): this;
prependOnceListener(event: "message", listener: (value: any) => void): this;
prependOnceListener(event: "messageerror", listener: (error: Error) => void): this;
prependOnceListener(event: "online", listener: () => void): this;
prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): this;
removeListener(event: 'error', listener: (err: Error) => void): this;
removeListener(event: 'exit', listener: (exitCode: number) => void): this;
removeListener(event: 'message', listener: (value: any) => void): this;
removeListener(event: 'messageerror', listener: (error: Error) => void): this;
removeListener(event: 'online', listener: () => void): this;
removeListener(event: "error", listener: (err: Error) => void): this;
removeListener(event: "exit", listener: (exitCode: number) => void): this;
removeListener(event: "message", listener: (value: any) => void): this;
removeListener(event: "messageerror", listener: (error: Error) => void): this;
removeListener(event: "online", listener: () => void): this;
removeListener(event: string | symbol, listener: (...args: any[]) => void): this;
off(event: 'error', listener: (err: Error) => void): this;
off(event: 'exit', listener: (exitCode: number) => void): this;
off(event: 'message', listener: (value: any) => void): this;
off(event: 'messageerror', listener: (error: Error) => void): this;
off(event: 'online', listener: () => void): this;
off(event: "error", listener: (err: Error) => void): this;
off(event: "exit", listener: (exitCode: number) => void): this;
off(event: "message", listener: (value: any) => void): this;
off(event: "messageerror", listener: (error: Error) => void): this;
off(event: "online", listener: () => void): this;
off(event: string | symbol, listener: (...args: any[]) => void): this;

@@ -615,4 +615,4 @@ }

| {
message: any;
}
message: any;
}
| undefined;

@@ -658,3 +658,3 @@ type Serializable = string | object | number | boolean | bigint;

MessagePort as _MessagePort,
} from 'worker_threads';
} from "worker_threads";
global {

@@ -669,4 +669,3 @@ /**

BroadcastChannel: infer T;
}
? T
} ? T
: typeof _BroadcastChannel;

@@ -682,4 +681,3 @@

MessageChannel: infer T;
}
? T
} ? T
: typeof _MessageChannel;

@@ -692,12 +690,11 @@

*/
var MessagePort: typeof globalThis extends {
var MessagePort: typeof globalThis extends {
onmessage: any;
MessagePort: infer T;
}
? T
} ? T
: typeof _MessagePort;
}
}
declare module 'node:worker_threads' {
export * from 'worker_threads';
declare module "node:worker_threads" {
export * from "worker_threads";
}

@@ -93,4 +93,4 @@ /**

*/
declare module 'zlib' {
import * as stream from 'node:stream';
declare module "zlib" {
import * as stream from "node:stream";
interface ZlibOptions {

@@ -132,7 +132,7 @@ /**

| {
/**
* Each key is a `constants.BROTLI_*` constant.
*/
[key: number]: boolean | number;
}
/**
* Each key is a `constants.BROTLI_*` constant.
*/
[key: number]: boolean | number;
}
| undefined;

@@ -517,4 +517,4 @@ maxOutputLength?: number | undefined;

}
declare module 'node:zlib' {
export * from 'zlib';
declare module "node:zlib" {
export * from "zlib";
}

@@ -27,4 +27,4 @@ /**

*/
declare module 'tty' {
import * as net from 'node:net';
declare module "tty" {
import * as net from "node:net";
/**

@@ -85,13 +85,13 @@ * The `tty.isatty()` method returns `true` if the given `fd` is associated with

addListener(event: string, listener: (...args: any[]) => void): this;
addListener(event: 'resize', listener: () => void): this;
addListener(event: "resize", listener: () => void): this;
emit(event: string | symbol, ...args: any[]): boolean;
emit(event: 'resize'): boolean;
emit(event: "resize"): boolean;
on(event: string, listener: (...args: any[]) => void): this;
on(event: 'resize', listener: () => void): this;
on(event: "resize", listener: () => void): this;
once(event: string, listener: (...args: any[]) => void): this;
once(event: 'resize', listener: () => void): this;
once(event: "resize", listener: () => void): this;
prependListener(event: string, listener: (...args: any[]) => void): this;
prependListener(event: 'resize', listener: () => void): this;
prependListener(event: "resize", listener: () => void): this;
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'resize', listener: () => void): this;
prependOnceListener(event: "resize", listener: () => void): this;
/**

@@ -206,4 +206,4 @@ * `writeStream.clearLine()` clears the current line of this `WriteStream` in a

}
declare module 'node:tty' {
export * from 'tty';
declare module "node:tty" {
export * from "tty";
}

@@ -10,6 +10,6 @@ /**

*/
declare module 'url' {
import { Blob as NodeBlob } from 'node:buffer';
import { ClientRequestArgs } from 'node:http';
import { ParsedUrlQuery, ParsedUrlQueryInput } from 'node:querystring';
declare module "url" {
import { Blob as NodeBlob } from "node:buffer";
import { ClientRequestArgs } from "node:http";
import { ParsedUrlQuery, ParsedUrlQueryInput } from "node:querystring";
// Input to `url.format`

@@ -76,3 +76,7 @@ interface UrlObject {

function parse(urlString: string): UrlWithStringQuery;
function parse(urlString: string, parseQueryString: false | undefined, slashesDenoteHost?: boolean): UrlWithStringQuery;
function parse(
urlString: string,
parseQueryString: false | undefined,
slashesDenoteHost?: boolean,
): UrlWithStringQuery;
function parse(urlString: string, parseQueryString: true, slashesDenoteHost?: boolean): UrlWithParsedQuery;

@@ -771,3 +775,10 @@ function parse(urlString: string, parseQueryString: boolean, slashesDenoteHost?: boolean): Url;

class URLSearchParams implements Iterable<[string, string]> {
constructor(init?: URLSearchParams | string | Record<string, string | ReadonlyArray<string>> | Iterable<[string, string]> | ReadonlyArray<[string, string]>);
constructor(
init?:
| URLSearchParams
| string
| Record<string, string | ReadonlyArray<string>>
| Iterable<[string, string]>
| ReadonlyArray<[string, string]>,
);
/**

@@ -803,3 +814,6 @@ * Append a new name-value pair to the query string.

*/
forEach<TThis = this>(callback: (this: TThis, value: string, name: string, searchParams: URLSearchParams) => void, thisArg?: TThis): void;
forEach<TThis = this>(
callback: (this: TThis, value: string, name: string, searchParams: URLSearchParams) => void,
thisArg?: TThis,
): void;
/**

@@ -886,3 +900,3 @@ * Returns the value of the first name-value pair whose name is `name`. If there

}
import { URL as _URL, URLSearchParams as _URLSearchParams } from 'url';
import { URL as _URL, URLSearchParams as _URLSearchParams } from "url";
global {

@@ -903,4 +917,3 @@ interface URLSearchParams extends _URLSearchParams {}

URL: infer T;
}
? T
} ? T
: typeof _URL;

@@ -915,9 +928,8 @@ /**

URLSearchParams: infer T;
}
? T
} ? T
: typeof _URLSearchParams;
}
}
declare module 'node:url' {
export * from 'url';
declare module "node:url" {
export * from "url";
}

@@ -9,4 +9,4 @@ /**

*/
declare module 'v8' {
import { Readable } from 'node:stream';
declare module "v8" {
import { Readable } from "node:stream";
interface HeapSpaceInfo {

@@ -540,4 +540,4 @@ space_name: string;

}
declare module 'node:v8' {
export * from 'v8';
declare module "node:v8" {
export * from "v8";
}

@@ -39,4 +39,4 @@ /**

*/
declare module 'vm' {
import { ImportAssertions } from 'node:module';
declare module "vm" {
import { ImportAssertions } from "node:module";
interface Context extends NodeJS.Dict<any> {}

@@ -71,3 +71,5 @@ interface BaseOptions {

*/
importModuleDynamically?: ((specifier: string, script: Script, importAssertions: ImportAssertions) => Module) | undefined;
importModuleDynamically?:
| ((specifier: string, script: Script, importAssertions: ImportAssertions) => Module)
| undefined;
}

@@ -97,3 +99,3 @@ interface RunningScriptOptions extends BaseOptions {

*/
contextName?: CreateContextOptions['name'];
contextName?: CreateContextOptions["name"];
/**

@@ -104,16 +106,16 @@ * Origin corresponding to the newly created context for display purposes. The origin should be formatted like a URL,

*/
contextOrigin?: CreateContextOptions['origin'];
contextCodeGeneration?: CreateContextOptions['codeGeneration'];
contextOrigin?: CreateContextOptions["origin"];
contextCodeGeneration?: CreateContextOptions["codeGeneration"];
/**
* If set to `afterEvaluate`, microtasks will be run immediately after the script has run.
*/
microtaskMode?: CreateContextOptions['microtaskMode'];
microtaskMode?: CreateContextOptions["microtaskMode"];
}
interface RunningCodeOptions extends RunningScriptOptions {
cachedData?: ScriptOptions['cachedData'];
importModuleDynamically?: ScriptOptions['importModuleDynamically'];
cachedData?: ScriptOptions["cachedData"];
importModuleDynamically?: ScriptOptions["importModuleDynamically"];
}
interface RunningCodeInNewContextOptions extends RunningScriptInNewContextOptions {
cachedData?: ScriptOptions['cachedData'];
importModuleDynamically?: ScriptOptions['importModuleDynamically'];
cachedData?: ScriptOptions["cachedData"];
importModuleDynamically?: ScriptOptions["importModuleDynamically"];
}

@@ -155,14 +157,14 @@ interface CompileFunctionOptions extends BaseOptions {

| {
/**
* If set to false any calls to eval or function constructors (Function, GeneratorFunction, etc)
* will throw an EvalError.
* @default true
*/
strings?: boolean | undefined;
/**
* If set to false any attempt to compile a WebAssembly module will throw a WebAssembly.CompileError.
* @default true
*/
wasm?: boolean | undefined;
}
/**
* If set to false any calls to eval or function constructors (Function, GeneratorFunction, etc)
* will throw an EvalError.
* @default true
*/
strings?: boolean | undefined;
/**
* If set to false any attempt to compile a WebAssembly module will throw a WebAssembly.CompileError.
* @default true
*/
wasm?: boolean | undefined;
}
| undefined;

@@ -172,5 +174,5 @@ /**

*/
microtaskMode?: 'afterEvaluate' | undefined;
microtaskMode?: "afterEvaluate" | undefined;
}
type MeasureMemoryMode = 'summary' | 'detailed';
type MeasureMemoryMode = "summary" | "detailed";
interface MeasureMemoryOptions {

@@ -184,3 +186,3 @@ /**

*/
execution?: 'default' | 'eager' | undefined;
execution?: "default" | "eager" | undefined;
}

@@ -419,3 +421,7 @@ interface MemoryMeasurement {

*/
function runInNewContext(code: string, contextObject?: Context, options?: RunningCodeInNewContextOptions | string): any;
function runInNewContext(
code: string,
contextObject?: Context,
options?: RunningCodeInNewContextOptions | string,
): any;
/**

@@ -492,6 +498,10 @@ * `vm.runInThisContext()` compiles `code`, runs it within the context of the

*/
function compileFunction(code: string, params?: ReadonlyArray<string>, options?: CompileFunctionOptions): Function & {
cachedData?: Script['cachedData'] | undefined;
cachedDataProduced?: Script['cachedDataProduced'] | undefined;
cachedDataRejected?: Script['cachedDataRejected'] | undefined;
function compileFunction(
code: string,
params?: ReadonlyArray<string>,
options?: CompileFunctionOptions,
): Function & {
cachedData?: Script["cachedData"] | undefined;
cachedDataProduced?: Script["cachedDataProduced"] | undefined;
cachedDataRejected?: Script["cachedDataRejected"] | undefined;
};

@@ -556,7 +566,11 @@ /**

interface ModuleEvaluateOptions {
timeout?: RunningScriptOptions['timeout'] | undefined;
breakOnSigint?: RunningScriptOptions['breakOnSigint'] | undefined;
timeout?: RunningScriptOptions["timeout"] | undefined;
breakOnSigint?: RunningScriptOptions["breakOnSigint"] | undefined;
}
type ModuleLinker = (specifier: string, referencingModule: Module, extra: { assert: Object }) => Module | Promise<Module>;
type ModuleStatus = 'unlinked' | 'linking' | 'linked' | 'evaluating' | 'evaluated' | 'errored';
type ModuleLinker = (
specifier: string,
referencingModule: Module,
extra: { assert: Object },
) => Module | Promise<Module>;
type ModuleStatus = "unlinked" | "linking" | "linked" | "evaluating" | "evaluated" | "errored";
class Module {

@@ -608,6 +622,6 @@ /**

identifier?: string | undefined;
cachedData?: ScriptOptions['cachedData'] | undefined;
cachedData?: ScriptOptions["cachedData"] | undefined;
context?: Context | undefined;
lineOffset?: BaseOptions['lineOffset'] | undefined;
columnOffset?: BaseOptions['columnOffset'] | undefined;
lineOffset?: BaseOptions["lineOffset"] | undefined;
columnOffset?: BaseOptions["columnOffset"] | undefined;
/**

@@ -617,3 +631,3 @@ * Called during evaluation of this module to initialize the `import.meta`.

initializeImportMeta?: ((meta: ImportMeta, module: SourceTextModule) => void) | undefined;
importModuleDynamically?: ScriptOptions['importModuleDynamically'] | undefined;
importModuleDynamically?: ScriptOptions["importModuleDynamically"] | undefined;
}

@@ -645,3 +659,7 @@ class SourceTextModule extends Module {

*/
constructor(exportNames: string[], evaluateCallback: (this: SyntheticModule) => void, options?: SyntheticModuleOptions);
constructor(
exportNames: string[],
evaluateCallback: (this: SyntheticModule) => void,
options?: SyntheticModuleOptions,
);
/**

@@ -656,4 +674,4 @@ * This method is used after the module is linked to set the values of exports.

}
declare module 'node:vm' {
export * from 'vm';
declare module "node:vm" {
export * from "vm";
}

@@ -73,3 +73,3 @@ /**

*/
declare module 'wasi' {
declare module "wasi" {
interface WASIOptions {

@@ -157,4 +157,4 @@ /**

}
declare module 'node:wasi' {
export * from 'wasi';
declare module "node:wasi" {
export * from "wasi";
}

@@ -54,11 +54,11 @@ /**

*/
declare module 'worker_threads' {
import { Blob } from 'node:buffer';
import { Context } from 'node:vm';
import { EventEmitter } from 'node:events';
import { EventLoopUtilityFunction } from 'node:perf_hooks';
import { FileHandle } from 'node:fs/promises';
import { Readable, Writable } from 'node:stream';
import { URL } from 'node:url';
import { X509Certificate } from 'node:crypto';
declare module "worker_threads" {
import { Blob } from "node:buffer";
import { Context } from "node:vm";
import { EventEmitter } from "node:events";
import { EventLoopUtilityFunction } from "node:perf_hooks";
import { FileHandle } from "node:fs/promises";
import { Readable, Writable } from "node:stream";
import { URL } from "node:url";
import { X509Certificate } from "node:crypto";
const isMainThread: boolean;

@@ -209,33 +209,33 @@ const parentPort: null | MessagePort;

start(): void;
addListener(event: 'close', listener: () => void): this;
addListener(event: 'message', listener: (value: any) => void): this;
addListener(event: 'messageerror', listener: (error: Error) => void): this;
addListener(event: "close", listener: () => void): this;
addListener(event: "message", listener: (value: any) => void): this;
addListener(event: "messageerror", listener: (error: Error) => void): this;
addListener(event: string | symbol, listener: (...args: any[]) => void): this;
emit(event: 'close'): boolean;
emit(event: 'message', value: any): boolean;
emit(event: 'messageerror', error: Error): boolean;
emit(event: "close"): boolean;
emit(event: "message", value: any): boolean;
emit(event: "messageerror", error: Error): boolean;
emit(event: string | symbol, ...args: any[]): boolean;
on(event: 'close', listener: () => void): this;
on(event: 'message', listener: (value: any) => void): this;
on(event: 'messageerror', listener: (error: Error) => void): this;
on(event: "close", listener: () => void): this;
on(event: "message", listener: (value: any) => void): this;
on(event: "messageerror", listener: (error: Error) => void): this;
on(event: string | symbol, listener: (...args: any[]) => void): this;
once(event: 'close', listener: () => void): this;
once(event: 'message', listener: (value: any) => void): this;
once(event: 'messageerror', listener: (error: Error) => void): this;
once(event: "close", listener: () => void): this;
once(event: "message", listener: (value: any) => void): this;
once(event: "messageerror", listener: (error: Error) => void): this;
once(event: string | symbol, listener: (...args: any[]) => void): this;
prependListener(event: 'close', listener: () => void): this;
prependListener(event: 'message', listener: (value: any) => void): this;
prependListener(event: 'messageerror', listener: (error: Error) => void): this;
prependListener(event: "close", listener: () => void): this;
prependListener(event: "message", listener: (value: any) => void): this;
prependListener(event: "messageerror", listener: (error: Error) => void): this;
prependListener(event: string | symbol, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'close', listener: () => void): this;
prependOnceListener(event: 'message', listener: (value: any) => void): this;
prependOnceListener(event: 'messageerror', listener: (error: Error) => void): this;
prependOnceListener(event: "close", listener: () => void): this;
prependOnceListener(event: "message", listener: (value: any) => void): this;
prependOnceListener(event: "messageerror", listener: (error: Error) => void): this;
prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): this;
removeListener(event: 'close', listener: () => void): this;
removeListener(event: 'message', listener: (value: any) => void): this;
removeListener(event: 'messageerror', listener: (error: Error) => void): this;
removeListener(event: "close", listener: () => void): this;
removeListener(event: "message", listener: (value: any) => void): this;
removeListener(event: "messageerror", listener: (error: Error) => void): this;
removeListener(event: string | symbol, listener: (...args: any[]) => void): this;
off(event: 'close', listener: () => void): this;
off(event: 'message', listener: (value: any) => void): this;
off(event: 'messageerror', listener: (error: Error) => void): this;
off(event: "close", listener: () => void): this;
off(event: "message", listener: (value: any) => void): this;
off(event: "messageerror", listener: (error: Error) => void): this;
off(event: string | symbol, listener: (...args: any[]) => void): this;

@@ -439,49 +439,49 @@ }

getHeapSnapshot(): Promise<Readable>;
addListener(event: 'error', listener: (err: Error) => void): this;
addListener(event: 'exit', listener: (exitCode: number) => void): this;
addListener(event: 'message', listener: (value: any) => void): this;
addListener(event: 'messageerror', listener: (error: Error) => void): this;
addListener(event: 'online', listener: () => void): this;
addListener(event: "error", listener: (err: Error) => void): this;
addListener(event: "exit", listener: (exitCode: number) => void): this;
addListener(event: "message", listener: (value: any) => void): this;
addListener(event: "messageerror", listener: (error: Error) => void): this;
addListener(event: "online", listener: () => void): this;
addListener(event: string | symbol, listener: (...args: any[]) => void): this;
emit(event: 'error', err: Error): boolean;
emit(event: 'exit', exitCode: number): boolean;
emit(event: 'message', value: any): boolean;
emit(event: 'messageerror', error: Error): boolean;
emit(event: 'online'): boolean;
emit(event: "error", err: Error): boolean;
emit(event: "exit", exitCode: number): boolean;
emit(event: "message", value: any): boolean;
emit(event: "messageerror", error: Error): boolean;
emit(event: "online"): boolean;
emit(event: string | symbol, ...args: any[]): boolean;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'exit', listener: (exitCode: number) => void): this;
on(event: 'message', listener: (value: any) => void): this;
on(event: 'messageerror', listener: (error: Error) => void): this;
on(event: 'online', listener: () => void): this;
on(event: "error", listener: (err: Error) => void): this;
on(event: "exit", listener: (exitCode: number) => void): this;
on(event: "message", listener: (value: any) => void): this;
on(event: "messageerror", listener: (error: Error) => void): this;
on(event: "online", listener: () => void): this;
on(event: string | symbol, listener: (...args: any[]) => void): this;
once(event: 'error', listener: (err: Error) => void): this;
once(event: 'exit', listener: (exitCode: number) => void): this;
once(event: 'message', listener: (value: any) => void): this;
once(event: 'messageerror', listener: (error: Error) => void): this;
once(event: 'online', listener: () => void): this;
once(event: "error", listener: (err: Error) => void): this;
once(event: "exit", listener: (exitCode: number) => void): this;
once(event: "message", listener: (value: any) => void): this;
once(event: "messageerror", listener: (error: Error) => void): this;
once(event: "online", listener: () => void): this;
once(event: string | symbol, listener: (...args: any[]) => void): this;
prependListener(event: 'error', listener: (err: Error) => void): this;
prependListener(event: 'exit', listener: (exitCode: number) => void): this;
prependListener(event: 'message', listener: (value: any) => void): this;
prependListener(event: 'messageerror', listener: (error: Error) => void): this;
prependListener(event: 'online', listener: () => void): this;
prependListener(event: "error", listener: (err: Error) => void): this;
prependListener(event: "exit", listener: (exitCode: number) => void): this;
prependListener(event: "message", listener: (value: any) => void): this;
prependListener(event: "messageerror", listener: (error: Error) => void): this;
prependListener(event: "online", listener: () => void): this;
prependListener(event: string | symbol, listener: (...args: any[]) => void): this;
prependOnceListener(event: 'error', listener: (err: Error) => void): this;
prependOnceListener(event: 'exit', listener: (exitCode: number) => void): this;
prependOnceListener(event: 'message', listener: (value: any) => void): this;
prependOnceListener(event: 'messageerror', listener: (error: Error) => void): this;
prependOnceListener(event: 'online', listener: () => void): this;
prependOnceListener(event: "error", listener: (err: Error) => void): this;
prependOnceListener(event: "exit", listener: (exitCode: number) => void): this;
prependOnceListener(event: "message", listener: (value: any) => void): this;
prependOnceListener(event: "messageerror", listener: (error: Error) => void): this;
prependOnceListener(event: "online", listener: () => void): this;
prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): this;
removeListener(event: 'error', listener: (err: Error) => void): this;
removeListener(event: 'exit', listener: (exitCode: number) => void): this;
removeListener(event: 'message', listener: (value: any) => void): this;
removeListener(event: 'messageerror', listener: (error: Error) => void): this;
removeListener(event: 'online', listener: () => void): this;
removeListener(event: "error", listener: (err: Error) => void): this;
removeListener(event: "exit", listener: (exitCode: number) => void): this;
removeListener(event: "message", listener: (value: any) => void): this;
removeListener(event: "messageerror", listener: (error: Error) => void): this;
removeListener(event: "online", listener: () => void): this;
removeListener(event: string | symbol, listener: (...args: any[]) => void): this;
off(event: 'error', listener: (err: Error) => void): this;
off(event: 'exit', listener: (exitCode: number) => void): this;
off(event: 'message', listener: (value: any) => void): this;
off(event: 'messageerror', listener: (error: Error) => void): this;
off(event: 'online', listener: () => void): this;
off(event: "error", listener: (err: Error) => void): this;
off(event: "exit", listener: (exitCode: number) => void): this;
off(event: "message", listener: (value: any) => void): this;
off(event: "messageerror", listener: (error: Error) => void): this;
off(event: "online", listener: () => void): this;
off(event: string | symbol, listener: (...args: any[]) => void): this;

@@ -615,4 +615,4 @@ }

| {
message: any;
}
message: any;
}
| undefined;

@@ -658,3 +658,3 @@ type Serializable = string | object | number | boolean | bigint;

MessagePort as _MessagePort,
} from 'worker_threads';
} from "worker_threads";
global {

@@ -669,4 +669,3 @@ /**

BroadcastChannel: infer T;
}
? T
} ? T
: typeof _BroadcastChannel;

@@ -682,4 +681,3 @@

MessageChannel: infer T;
}
? T
} ? T
: typeof _MessageChannel;

@@ -692,12 +690,11 @@

*/
var MessagePort: typeof globalThis extends {
var MessagePort: typeof globalThis extends {
onmessage: any;
MessagePort: infer T;
}
? T
} ? T
: typeof _MessagePort;
}
}
declare module 'node:worker_threads' {
export * from 'worker_threads';
declare module "node:worker_threads" {
export * from "worker_threads";
}

@@ -93,4 +93,4 @@ /**

*/
declare module 'zlib' {
import * as stream from 'node:stream';
declare module "zlib" {
import * as stream from "node:stream";
interface ZlibOptions {

@@ -132,7 +132,7 @@ /**

| {
/**
* Each key is a `constants.BROTLI_*` constant.
*/
[key: number]: boolean | number;
}
/**
* Each key is a `constants.BROTLI_*` constant.
*/
[key: number]: boolean | number;
}
| undefined;

@@ -517,4 +517,4 @@ maxOutputLength?: number | undefined;

}
declare module 'node:zlib' {
export * from 'zlib';
declare module "node:zlib" {
export * from "zlib";
}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc