yrik 0fb20a58e3 提交 4 years ago
..
index.js eec7f449c9 first commit 4 years ago
package.json 0fb20a58e3 提交 4 years ago
readme.md eec7f449c9 first commit 4 years ago

readme.md

is-regexp Build Status

Check whether a variable is a regular expression

Install

$ npm install --save is-regexp

Usage

var isRegexp = require('is-regexp');

isRegexp('unicorn');
//=> false

isRegexp(/unicorn/);
//=> true

isRegexp(new RegExp('unicorn'));
//=> true

License

MIT © Sindre Sorhus