ClientHttp2Session.once - Node documentation
method ClientHttp2Session.once

Usage in Deno

import { type ClientHttp2Session } from "node:http2";
ClientHttp2Session.once(
event: "altsvc",
listener: (
alt: string,
origin: string,
stream: number,
) => void
,
): this

Parameters

event: "altsvc"
listener: (
alt: string,
origin: string,
stream: number,
) => void

Return Type

this
ClientHttp2Session.once(
event: "origin",
listener: (origins: string[]) => void,
): this

Parameters

event: "origin"
listener: (origins: string[]) => void

Return Type

this
ClientHttp2Session.once(
event: "connect",
listener: (
socket: net.Socket | tls.TLSSocket,
) => void
,
): this

Parameters

event: "connect"
listener: (
socket: net.Socket | tls.TLSSocket,
) => void

Return Type

this
ClientHttp2Session.once(
event: "stream",
listener: () => void,
): this

Parameters

event: "stream"
listener: () => void

Return Type

this
ClientHttp2Session.once(
event: string | symbol,
listener: (...args: any[]) => void,
): this

Parameters

event: string | symbol
listener: (...args: any[]) => void

Return Type

this