MCPcopy Create free account
hub / github.com/ChromeDevTools/chrome-devtools-mcp / getTextContent

Function getTextContent

tests/utils.ts:60–67  ·  view source on GitHub ↗
(
  content: CallToolResult['content'][number],
)

Source from the content-addressed store, hash-verified

58}
59
60export function getTextContent(
61 content: CallToolResult['content'][number],
62): string {
63 if (content.type === 'text') {
64 return content.text;
65 }
66 throw new Error(`Expected text content but got ${content.type}`);
67}
68
69export function getImageContent(content: CallToolResult['content'][number]): {
70 data: string;

Callers 7

testIncludesWebmcpToolsFunction · 0.85
input.test.tsFile · 0.85
pwa.test.tsFile · 0.85
console.test.tsFile · 0.85

Calls

no outgoing calls

Tested by 2

testIncludesWebmcpToolsFunction · 0.68