export default function SanitizeString(str, punctuation = false, space = false, replace = false) { const r = new RegExp(`[^\\d${ space ? `\\s` : `` }\\.\\-@${ punctuation ? `"'=+,;«»()&!?%` : ``}\\p{A-z}\u0401\u0451\u0410-\u044f]`, 'gi'); return str.replace(r, replace ? ' ' : ''); }