Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/mksglu/context-mode
/ functions
Functions
5,006 in github.com/mksglu/context-mode
⨍
Functions
5,006
◇
Types & classes
292
↓ 2,404 callers
Function
test
( name: string, fn: () => Promise<void>, )
tests/mcp-integration.ts:81
↓ 1,899 callers
Function
it
(t=process.env)
server.bundle.mjs:153
↓ 1,028 callers
Method
includes
(e,n)
cli.bundle.mjs:459
↓ 1,009 callers
Method
ok
(e)
cli.bundle.mjs:494
↓ 512 callers
Method
parse
(e,n)
cli.bundle.mjs:459
↓ 405 callers
Method
trim
()
cli.bundle.mjs:459
↓ 392 callers
Method
get
(...params: unknown[])
src/db-base.ts:33
↓ 355 callers
Method
prepare
(sql: string)
src/session/analytics.ts:37
↓ 329 callers
Method
close
()
tests/store.test.ts:1978
↓ 298 callers
Method
startsWith
(e,n)
cli.bundle.mjs:459
↓ 263 callers
Method
optional
()
cli.bundle.mjs:459
↓ 212 callers
Function
extractEvents
(rawInput: HookInput)
src/session/extract.ts:2710
↓ 205 callers
Method
optional
()
server.bundle.mjs:195
↓ 203 callers
Method
run
()
src/runPool.ts:21
↓ 202 callers
Method
index
(e)
cli.bundle.mjs:440
↓ 181 callers
Method
all
(...params: unknown[])
src/db-base.ts:34
↓ 174 callers
Function
routePreToolUse
(toolName, toolInput, projectDir, platform, sessionId, options = {})
hooks/core/routing.mjs:670
↓ 173 callers
Method
toLowerCase
()
cli.bundle.mjs:459
↓ 170 callers
Method
has
(e)
cli.bundle.mjs:484
↓ 167 callers
Method
getSettingsPath
Path to the platform's settings file (e.g., ~/.claude/settings.json).
src/adapters/types.ts:213
↓ 165 callers
Function
x
(t,e)
cli.bundle.mjs:2
↓ 163 callers
Method
execute
(input: { language: "shell"; code: string; timeout: number | undefined; cwd?: string })
src/server.ts:1445
↓ 135 callers
Function
S
(t)
server.bundle.mjs:222
↓ 135 callers
Method
check
Synchronous check thunk. Returns OK or FAIL with optional detail.
src/adapters/types.ts:355
↓ 135 callers
Method
insertEvent
(e,n,r="PostToolUse",o,s)
cli.bundle.mjs:144
↓ 135 callers
Function
w
(t)
cli.bundle.mjs:486
↓ 132 callers
Method
endsWith
(e,n)
cli.bundle.mjs:459
↓ 131 callers
Method
max
(e,n)
cli.bundle.mjs:459
↓ 127 callers
Method
toString
()
cli.bundle.mjs:490
↓ 126 callers
Method
on
(event: "session_start", handler: HookHandler<{ type: "session_start" }>)
src/adapters/omp/plugin.ts:235
↓ 123 callers
Function
E
(t,e,n)
cli.bundle.mjs:459
↓ 123 callers
Function
v
(t,e,n)
server.bundle.mjs:195
↓ 118 callers
Method
isFinite
()
cli.bundle.mjs:459
↓ 114 callers
Method
includes
(e,n)
server.bundle.mjs:195
↓ 114 callers
Method
write
(e)
cli.bundle.mjs:459
↓ 107 callers
Function
e
(o)
cli.bundle.mjs:459
↓ 106 callers
Method
describe
(e)
cli.bundle.mjs:459
↓ 104 callers
Method
search
(e,n=3,r,o="AND",s,i="like")
cli.bundle.mjs:440
↓ 101 callers
Method
error
()
cli.bundle.mjs:459
↓ 100 callers
Method
indexPlainText
(e,n,r=20,o,s=Gc)
cli.bundle.mjs:440
↓ 98 callers
Function
detectPlatform
(clientInfo?: { name: string; version?: string })
src/adapters/detect.ts:367
↓ 96 callers
Method
assign
(e,n,r)
cli.bundle.mjs:491
↓ 96 callers
Method
ensureSession
(e,n)
cli.bundle.mjs:146
↓ 94 callers
Method
add
(e,...n)
cli.bundle.mjs:484
↓ 90 callers
Method
assign
(e,n,r)
server.bundle.mjs:3
↓ 84 callers
Method
searchWithFallback
(e,n=3,r,o,s="like",i)
cli.bundle.mjs:440
↓ 82 callers
Function
createStore
()
tests/store.test.ts:27
↓ 80 callers
Method
delete
(id: string)
tests/fixtures/source-example.ts:142
↓ 80 callers
Method
min
(e,n)
cli.bundle.mjs:459
↓ 80 callers
Method
parse
(e,n)
server.bundle.mjs:195
↓ 76 callers
Method
update
(id: string, input: UpdateUserInput)
tests/fixtures/source-example.ts:130
↓ 74 callers
Function
C
(t,e)
server.bundle.mjs:195
↓ 74 callers
Function
D
(t,e)
cli.bundle.mjs:459
↓ 73 callers
Function
L
(t,e)
cli.bundle.mjs:2
↓ 73 callers
Method
if
(e,n,r)
cli.bundle.mjs:491
↓ 73 callers
Method
if
(e,n,r)
server.bundle.mjs:3
↓ 73 callers
Method
trim
()
server.bundle.mjs:195
↓ 72 callers
Method
extend
(e)
cli.bundle.mjs:459
↓ 72 callers
Method
extend
(e)
server.bundle.mjs:195
↓ 71 callers
Function
I
(t,e)
server.bundle.mjs:2
↓ 71 callers
Method
getSessionDir
* Directory where session data is stored. * * NOTE — C2 narrowing (2026-05): this is the ONLY storage-path concern an * adapter exposes. Per-
src/adapters/types.ts:225
↓ 71 callers
Function
getSessionId
(input, opts = CLAUDE_OPTS)
hooks/session-helpers.mjs:364
↓ 70 callers
Function
makeEvent
(overrides: Partial<StoredEvent> & Pick<StoredEvent, "type" | "category">)
tests/session/session-snapshot.test.ts:10
↓ 69 callers
Function
assert
(condition: boolean, msg: string)
tests/mcp-integration.ts:77
↓ 69 callers
Method
toString
()
server.bundle.mjs:2
↓ 68 callers
Function
N
(t,e)
server.bundle.mjs:222
↓ 68 callers
Function
U
(t,e)
cli.bundle.mjs:486
↓ 68 callers
Function
createStore
()
tests/core/search.test.ts:30
↓ 68 callers
Method
getConfigDir
* Platform config directory. * * Contract: ALWAYS returns an absolute path. Never returns a relative * segment, never returns an empty string
src/adapters/types.ts:245
↓ 66 callers
Function
formatReport
( report: FullReport, version?: string, latestVersion?: string | null, opts?: { lifetime?: Lifetim
src/session/analytics.ts:2827
↓ 64 callers
Function
e
(o)
server.bundle.mjs:195
↓ 64 callers
Function
hashProjectDirCanonical
(projectDir: string)
src/session/db.ts:430
↓ 62 callers
Function
buildResumeSnapshot
( events: StoredEvent[], opts?: BuildSnapshotOpts, )
src/session/snapshot.ts:472
↓ 61 callers
Function
makeReport
(overrides: Partial<FullReport> = {})
tests/analytics/format-report.test.ts:22
↓ 60 callers
Method
close
()
hooks/session-db.bundle.mjs:1
↓ 60 callers
Method
parsePreToolUseInput
Parse raw PreToolUse input into normalized form.
src/adapters/types.ts:185
↓ 58 callers
Function
makeEvent
(type: string, data: string, ts = Date.now())
tests/session/project-attribution.test.ts:18
↓ 58 callers
Function
registerPiExtension
( mockApi: ReturnType<typeof createMockPiApi>, opts?: { projectDir?: string }, )
tests/pi-extension.test.ts:72
↓ 57 callers
Function
U
(t,e)
server.bundle.mjs:222
↓ 57 callers
Function
getSessionDBPath
(opts = CLAUDE_OPTS, projectDirOverride)
hooks/session-helpers.mjs:408
↓ 57 callers
Function
q
(t,e)
cli.bundle.mjs:486
↓ 56 callers
Function
loadSessionDB
()
hooks/session-loaders.mjs:38
↓ 56 callers
Function
safeString
Null-safe string coercion — no truncation, preserves full data.
src/session/extract.ts:86
↓ 55 callers
Function
_
(t)
hooks/session-extract.bundle.mjs:2
↓ 54 callers
Function
p
()
cli.bundle.mjs:494
↓ 53 callers
Method
dirty
()
cli.bundle.mjs:459
↓ 53 callers
Method
dirty
()
server.bundle.mjs:195
↓ 52 callers
Function
createTestDB
Create a temporary SessionDB that auto-registers for cleanup.
tests/session/session-db.test.ts:30
↓ 52 callers
Method
formatPreToolUseResponse
Format a PreToolUse response into platform-specific output.
src/adapters/types.ts:199
↓ 52 callers
Method
has
(e)
server.bundle.mjs:220
↓ 52 callers
Function
readStdin
()
hooks/core/stdin.mjs:26
↓ 52 callers
Method
toLowerCase
()
server.bundle.mjs:195
↓ 51 callers
Method
_getOrReturnCtx
(e,n)
cli.bundle.mjs:459
↓ 51 callers
Method
_getOrReturnCtx
(e,n)
server.bundle.mjs:195
↓ 51 callers
Method
max
(e,n)
server.bundle.mjs:195
↓ 50 callers
Function
W
(t,e)
server.bundle.mjs:624
↓ 50 callers
Function
X
(t,e)
cli.bundle.mjs:625
↓ 50 callers
Method
generateHookConfig
Generate hook registration config for this platform.
src/adapters/types.ts:270
↓ 50 callers
Function
getInputProjectDir
(input, opts = CLAUDE_OPTS)
hooks/session-helpers.mjs:350
↓ 50 callers
Function
trackResponse
(toolName: string, response: ToolResult)
src/server.ts:885
next →
1–100 of 5,006, ranked by callers