Skip to content

isRegExp

Determine whether the input value is a RegExp.

Usage

ts
import { isRegExp } from 'rattail'

isRegExp(/abc/) // return true
isRegExp('abc') // return false

Arguments

ArgTypeDefaults
valueany

Return

Type
boolean