MCPcopy Create free account
hub / github.com/donghaxkim/react-rewrite / normalizeTextForMatch

Function normalizeTextForMatch

packages/cli/src/mdx-text.ts:552–557  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

550}
551
552function normalizeTextForMatch(value: string): string {
553 return value
554 .replace(/\u00a0/g, " ")
555 .replace(/[ \t\r\n\f]+/g, " ")
556 .trim();
557}
558
559function isCollapsibleWhitespaceChar(char: string): boolean {
560 return char === " " || char === "\n" || char === "\r" || char === "\t" || char === "\f" || char === "\u00a0";

Callers 3

selectBestContainerFunction · 0.85
visitFunction · 0.85
scoreCandidateFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected