MCPcopy
hub / github.com/coder/mux / isTabType

Function isTabType

src/browser/types/rightSidebar.ts:28–32  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

26
27/** Check if a value is a valid tab type (base tab or terminal instance). */
28export function isTabType(value: unknown): value is TabType {
29 if (typeof value !== "string") return false;
30 if (isBaseTabId(value)) return true;
31 return value === "terminal" || value.startsWith("terminal:");
32}
33
34/** Check if a tab type represents a terminal (either base "terminal" or "terminal:<sessionId>"). */
35export function isTerminalTab(tab: TabType): boolean {

Callers 5

isLayoutNodeFunction · 0.90
buildCoreSourcesFunction · 0.90
RightSidebarComponentFunction · 0.90

Calls 1

isBaseTabIdFunction · 0.90

Tested by

no test coverage detected