MCPcopy Index your code
hub / github.com/codeaashu/claude-code / applyMarkdown

Function applyMarkdown

src/utils/markdown.ts:36–47  ·  view source on GitHub ↗
(
  content: string,
  theme: ThemeName,
  highlight: CliHighlight | null = null,
)

Source from the content-addressed store, hash-verified

34}
35
36export function applyMarkdown(
37 content: string,
38 theme: ThemeName,
39 highlight: CliHighlight | null = null,
40): string {
41 configureMarked()
42 return marked
43 .lexer(stripPromptXMLTags(content))
44 .map(_ => formatToken(_, theme, 0, null, null, highlight))
45 .join('')
46 .trim()
47}
48
49export function formatToken(
50 token: Token,

Callers 2

PreviewBoxBodyFunction · 0.85

Calls 3

configureMarkedFunction · 0.85
stripPromptXMLTagsFunction · 0.85
formatTokenFunction · 0.85

Tested by

no test coverage detected