MCPcopy
hub / github.com/prisma/prisma / highlight

Function highlight

packages/internals/src/highlight/highlight.ts:17–20  ·  view source on GitHub ↗
(str: string, grammar: SyntaxDefinition)

Source from the content-addressed store, hash-verified

15}
16
17function highlight(str: string, grammar: SyntaxDefinition): any {
18 const tokens = Prism.tokenize(str, grammar)
19 return tokens.map((t) => Token.stringify(t)).join('')
20}

Callers 3

highlightDatamodelFunction · 0.70
highlightSqlFunction · 0.70
highlightTSFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected