Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/anomalyco/opencode
/ onClose
Function
onClose
packages/opencode/test/cli/run/runtime.queue.test.ts:29–39 ·
view source on GitHub ↗
(fn)
Source
from the content-addressed store, hash-verified
27
}
28
},
29
onClose(fn) {
30
if
(closed) {
31
fn()
32
return
() => {}
33
}
34
35
closes.add(fn)
36
return
() => {
37
closes.delete(fn)
38
}
39
},
40
event(next) {
41
events.push(next)
42
},
Callers
nothing calls this directly
Calls
3
add
Method · 0.65
fn
Function · 0.50
delete
Method · 0.45
Tested by
no test coverage detected