matchRegex

Description

Match when the provided regular expression matches, adds match array to Context state.

Example

matchRegex(/^[Hh]elp( me)?!?$/)

// Matching: "Help!"
// Matching: "help me"
// Not matching: "Please help me"

Usage

matchRegex(regex)

Parameters

regex:
RegExpResolvable