MCPcopy Create free account
hub / github.com/Effect-TS/effect / escapeCode

Function escapeCode

packages/effect/src/encoding/Yaml.ts:1654–1655  ·  view source on GitHub ↗
(code: number)

Source from the content-addressed store, hash-verified

1652}
1653
1654const escapeCode = (code: number): string =>
1655 code < 0x100 ? `\\x${code.toString(16).padStart(2, "0")}` : `\\u${code.toString(16).padStart(4, "0")}`
1656
1657const doubleQuote = (text: string): string => {
1658 let output = ""

Callers 1

doubleQuoteFunction · 0.85

Calls 1

toStringMethod · 0.65

Tested by

no test coverage detected