Returns true
if the given object
is a RegExp
. Otherwise, returns false
.
const util = require('util');
util.isRegExp(/some regexp/);
// Returns: true
util.isRegExp(new RegExp('another regexp'));
// Returns: true
util.isRegExp({});
// Returns: false
Since v4.0.0 - Deprecated
Generated using TypeDoc
Returns
true
if the givenobject
is aRegExp
. Otherwise, returnsfalse
.Deprecated
Since v4.0.0 - Deprecated