Package: effect
Module: Predicate
A refinement that checks if a value is a RegExp.
Example
import * as assert from "node:assert"
import { Predicate } from "effect"
assert.strictEqual(Predicate.isRegExp(/a/), true)
assert.strictEqual(Predicate.isRegExp(new RegExp("a")), true)
assert.strictEqual(Predicate.isRegExp("/a/"), false)
Signature
declare const isRegExp: (input: unknown) => input is RegExp
Since v3.9.0