Normalize a string for matching operations.
The string to normalize
Normalized string suitable for title matching
export function normalizeForMatching(str: string): string { return str .toLowerCase() .replaceAll("-", "") .replaceAll(/[^\w\s]/g, "") .replaceAll(/\s+/g, " ") .replaceAll("_", " ") .trim();} Copy
export function normalizeForMatching(str: string): string { return str .toLowerCase() .replaceAll("-", "") .replaceAll(/[^\w\s]/g, "") .replaceAll(/\s+/g, " ") .replaceAll("_", " ") .trim();}
Normalize a string for matching operations.