MCPcopy Create free account
hub / github.com/ecomfe/tempad-dev / escapeJsTemplateLiteralText

Function escapeJsTemplateLiteralText

packages/extension/utils/string.ts:60–65  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

58}
59
60export function escapeJsTemplateLiteralText(str: string) {
61 return str.replace(
62 JS_TEMPLATE_LITERAL_ESCAPE_RE,
63 (match) => JS_TEMPLATE_LITERAL_ESCAPES[match] ?? match
64 )
65}
66
67export function stringify(value: unknown) {
68 return stringifyObject(value, { indent: ' ' })

Callers 2

stringifyValueFunction · 0.90
string.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected