MCPcopy
hub / github.com/Eugeny/tabby / subscribe

Method subscribe

tabby-electron/src/pty.ts:72–77  ·  view source on GitHub ↗
(event: string, handler: (..._: any[]) => void)

Source from the content-addressed store, hash-verified

70 }
71
72 subscribe (event: string, handler: (..._: any[]) => void): void {
73 const key = `pty:${this.id}:${event}`
74 const newHandler = (_event, ...args) => handler(...args)
75 this.subscriptions.set(key, newHandler)
76 ipcRenderer.on(key, newHandler)
77 }
78
79 ackData (length: number): void {
80 ipcRenderer.send('pty:ack-data', this.id, length)

Callers 15

constructorMethod · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
attachMethod · 0.45
editMethod · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
constructorMethod · 0.45
setupWindowManagementMethod · 0.45

Calls 2

setMethod · 0.80
onMethod · 0.80

Tested by

no test coverage detected