wishthis/node_modules/is-regexp
2022-04-08 12:55:35 +02:00
..
index.js Add production dependencies 2022-01-21 09:28:41 +01:00
package.json Install yarn 2022-04-08 12:55:35 +02:00
readme.md Add production dependencies 2022-01-21 09:28:41 +01:00

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