blob: afbfc1e60fca88672e0db730d3c9d5f613a538e2 (
plain) (
blame)
1
2
3
4
5
6
|
export const DOUBLE_WHITE_SPACE = /\s\s+/g;
export const SPECIAL_CHAR = /[@#`:\r\n\t\f\v\p{C}]/gu;
export function trimSpecial(str: string) {
return str.replace(SPECIAL_CHAR, "").replace(DOUBLE_WHITE_SPACE, " ").trim();
}
|