Urara-Blog/node_modules/.pnpm-store/v3/files/61/7f0adf9bfb801b707bd86d6c724994c2c4eae8a858405e428beb6f708bdf0045029c19daf885b69b897e90e10726b3e215741360ef59536968c67d223f38c2
2022-08-14 01:14:53 +08:00

27 lines
552 B
Text

# escape-string-regexp [![Build Status](https://travis-ci.org/sindresorhus/escape-string-regexp.svg?branch=master)](https://travis-ci.org/sindresorhus/escape-string-regexp)
> Escape RegExp special characters
## Install
```
$ npm install --save escape-string-regexp
```
## Usage
```js
const escapeStringRegexp = require('escape-string-regexp');
const escapedString = escapeStringRegexp('how much $ for a unicorn?');
//=> 'how much \$ for a unicorn\?'
new RegExp(escapedString);
```
## License
MIT © [Sindre Sorhus](http://sindresorhus.com)