8 lines
241 B
JavaScript
8 lines
241 B
JavaScript
// Metro module 10667 (f10668).
|
|
export default function escapeStringRegexp(a0) {
|
|
if (typeof a0 !== "string") {
|
|
throw new TypeError("Expected a string");
|
|
}
|
|
return a0.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
};
|