MCPcopy
hub / github.com/socketio/socket.io / createSocket

Function createSocket

packages/engine.io-client/test/webtransport.mjs:82–101  ·  packages/engine.io-client/test/webtransport.mjs::createSocket
(port, certificate, opts)

Source from the content-addressed store, hash-verified

80}
81
82function createSocket(port, certificate, opts) {
83 return new Socket(
84 `http:class="cm">//127.0.0.1:${port}`,
85 Object.assign(
86 {
87 transportOptions: {
88 webtransport: {
89 serverCertificateHashes: [
90 {
91 algorithm: class="st">"sha-256",
92 value: certificate.hash,
93 },
94 ],
95 },
96 },
97 },
98 opts,
99 ),
100 );
101}
102
103describe(class="st">"WebTransport", () => {
104 it(class="st">"should allow to connect with WebTransport directly", (done) => {

Callers 1

webtransport.mjsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected