Returns a regex pattern that escaped the given pattern
Optional
the pattern to inspect
a regex pattern that escaped the given pattern
escapePattern('\\'); // '\\\\'escapePattern('-+='); // '\\-\\+=' Copy
escapePattern('\\'); // '\\\\'escapePattern('-+='); // '\\-\\+='
Returns a regex pattern that escaped the given pattern