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

Function emit

packages/effect/src/Stream.ts:1416–1418  ·  view source on GitHub ↗
(event: A)

Source from the content-addressed store, hash-verified

1414): Stream<A> =>
1415 callback<A>((queue) => {
1416 function emit(event: A) {
1417 Queue.offerUnsafe(queue, event)
1418 }
1419 return Effect.acquireRelease(
1420 Effect.sync(() => target.addEventListener(type, emit, options)),
1421 () => Effect.sync(() => target.removeEventListener(type, emit, options))

Callers 1

Calls 1

offerUnsafeMethod · 0.80

Tested by

no test coverage detected