Skip to main content
Http2ServerResponse.prototype.once - http2 - Node documentation
method Http2ServerResponse.prototype.once

Usage in Deno

import { Http2ServerResponse } from "node:http2";
Http2ServerResponse.prototype.once(
event: "close",
listener: () => void,
): this

Parameters

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

Return Type

this
Http2ServerResponse.prototype.once(
event: "drain",
listener: () => void,
): this

Parameters

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

Return Type

this
Http2ServerResponse.prototype.once(
event: "error",
listener: (error: Error) => void,
): this

Parameters

event: "error"
listener: (error: Error) => void

Return Type

this
Http2ServerResponse.prototype.once(
event: "finish",
listener: () => void,
): this

Parameters

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

Return Type

this
Http2ServerResponse.prototype.once(
event: "pipe",
listener: (src: stream.Readable) => void,
): this

Parameters

event: "pipe"
listener: (src: stream.Readable) => void

Return Type

this
Http2ServerResponse.prototype.once(
event: "unpipe",
listener: (src: stream.Readable) => void,
): this

Parameters

event: "unpipe"
listener: (src: stream.Readable) => void

Return Type

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

Parameters

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

Return Type

this