Namespace: Basic:isRegExp

Basic:isRegExp

Source:

Methods

isRegExp(value) → {Boolean}

Returns if a value is a regular expression.

Parameters:
Name Type Description
value *

the value to check

Source:
Returns:
true if value is a regular expression
Type
Boolean
Example
if( isRegExp(val) ){
  return val.test('foobar');
}