Update regExpUtils.js

This commit is contained in:
Mathias Bynens 2022-05-06 13:12:55 +02:00 committed by Philip Chimento
parent d361217eb7
commit 242128ec78
1 changed files with 6 additions and 0 deletions

View File

@ -89,6 +89,12 @@ function testPropertyOfStrings(args) {
}
}
// The exact same logic can be used to test extended character classes
// as enabled through the RegExp `v` flag. This is useful to test not
// just standalone properties of strings, but also string literals, and
// set operations.
const testExtendedCharacterClass = testPropertyOfStrings;
// Returns a function that validates a RegExp match result.
//
// Example: