MCPcopy Create free account
hub / github.com/Effect-TS/effect / echo

Function echo

packages/platform/deno/test/DenoSocketServer.test.ts:15–21  ·  view source on GitHub ↗
(socket: Socket.Socket)

Source from the content-addressed store, hash-verified

13)
14
15const echo = (socket: Socket.Socket) =>
16 Effect.scoped(
17 Effect.gen(function*() {
18 const write = yield* socket.writer
19 yield* socket.run(write)
20 })
21 )
22
23const makeTestConn = (onClose?: () => void): Deno.Conn => {
24 const transform = new TransformStream<Uint8Array>()

Callers

nothing calls this directly

Calls 1

runMethod · 0.45

Tested by

no test coverage detected