escapeString function

String escapeString(
  1. Pattern pattern
)

Implementation

String escapeString(Pattern pattern) {
  if (pattern is! String) return pattern.toString();
  return RegExp.escape(pattern);
}