MCPcopy Index your code
hub / github.com/srcbookdev/srcbook / tsDiagnosticMessage

Function tsDiagnosticMessage

packages/web/src/components/cells/code.tsx:85–90  ·  view source on GitHub ↗
(diagnostic: TsServerDiagnosticType)

Source from the content-addressed store, hash-verified

83}
84
85function tsDiagnosticMessage(diagnostic: TsServerDiagnosticType): string {
86 if (typeof diagnostic.text === 'string') {
87 return diagnostic.text;
88 }
89 return JSON.stringify(diagnostic); // Fallback
90}
91
92function convertTSDiagnosticToCM(diagnostic: TsServerDiagnosticType, code: string): Diagnostic {
93 const message = tsDiagnosticMessage(diagnostic);

Callers 1

convertTSDiagnosticToCMFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected