securityos/node_modules/core-js/modules/core.regexp.escape.js

6 lines
232 B
JavaScript
Raw Normal View History

2024-09-06 15:32:35 +00:00
// https://github.com/benjamingr/RexExp.escape
var $export = require('./_export');
var $re = require('./_replacer')(/[\\^$*+?.()|[\]{}]/g, '\\$&');
$export($export.S, 'RegExp', { escape: function escape(it) { return $re(it); } });