Sign in
apache
/
cordova-osx
/
6d00379c5b0ff30714987ad3172e30356620105b
/
.
/
node_modules
/
tap-mocha-reporter
/
lib
/
browser
/
escape-string-regexp.js
blob: 21a95663ed65ea4519605ce1d8995760bd356624 [
file
] [
log
] [
blame
]
'use strict'
;
var
matchOperatorsRe
=
/[|\\{}()[\]^$+*?.]/
g
;
module
.
exports
=
function
(
str
)
{
if
(
typeof
str
!==
'string'
)
{
throw
new
TypeError
(
'Expected a string'
);
}
return
str
.
replace
(
matchOperatorsRe
,
'\\$&'
);
};