MCPcopy Index your code
hub / github.com/sqlchat/sqlchat / on

Method on

src/utils/event-emitter.ts:18–23  ·  view source on GitHub ↗
(eventName: EventType, callback: Callback)

Source from the content-addressed store, hash-verified

16 }
17
18 on(eventName: EventType, callback: Callback) {
19 if (!this.events[eventName]) {
20 this.events[eventName] = [];
21 }
22 this.events[eventName].push(callback);
23 }
24
25 emit(eventName: EventType) {
26 const callbacks = this.events[eventName];

Callers 1

QuotaViewFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected