MCPcopy
hub / github.com/SPlayer-Dev/SPlayer / escape

Method escape

src/utils/lyric/lyricParser.ts:530–537  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

528 }
529
530 private escape(str: string): string {
531 return str
532 .replace(/&/g, "&")
533 .replace(/</g, "&lt;")
534 .replace(/>/g, "&gt;")
535 .replace(/"/g, "&quot;")
536 .replace(/'/g, "&apos;");
537 }
538
539 toString(indent = 0): string {
540 const spaces = " ".repeat(indent);

Callers 1

toStringMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected