createQuicConnector
createQuicConnector(
options):Connector<IMultiplexedConnection>
Defined in: net-quic/src/connect-quic.ts:75
A Connector over QUIC: each connection gets its own UDP socket, and
resolves once the handshake completed, with the protocol ALPN chose.
The target must be secure and offer at least one ALPN protocol. Its host is
sent as SNI and must be named by the server’s certificate; an IP address
target must be named as an IP address.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Connector<IMultiplexedConnection>
Example
Section titled “Example” const connect = createQuicConnector({ transport, abortCode: 0x102 }); const connection = await connect({ host: "localhost", port: 4433, secure: true, alpnProtocols: ["h3"], }); const stream = await connection.openStream("bidirectional"); ```;