regex
match
function match(regex: string, haystack: string) -> bool
Example
regex::match("\\d", "abc123") // returns `true`
regex::match("\\d", "abc") // returns `false`
find
function find(regex: string, haystack: string) -> [string]
Example
regex::find("a\\d", "a a3 c a45") // returns `["a3", "a4"]`
replace
function replace(regex: string, haystack: string, replace: string) -> string
Example
regex::replace("a\\d", "a a3 c a45", "b") // returns `"a b c b5"`