...
Regular Expressions (Regex)
Standard operators
Regular expressions utilize placeholder characters, referred to as operators, to match patterns within data and text. Wordbee’s library supports all Unicode characters but reserves some of them to be regex operators:
...
Code Block |
---|
[^abc] will match any character except 'a', 'b', or 'c' [^a-c] will match any character except 'a', 'b', or 'c' [^-abc] will match any character except '-', 'a', 'b', or 'c' [^abc\-] will match any character except 'a', 'b', 'c', or '-' |
Wildcards
Wildcards are placeholders in computing that can stand in for any character or group of characters, making it easier to find or match different variations of a word or phrase. These so called wildcard operators match one or more characters and can be combined with each other to create a wildcard pattern.
?
You can use the questionmark to match any single character. For example:
Code Block |
---|
locali?ation will match 'localization' and 'localisation' |
*
You can use the asterisk to match zero or more characters. For example:
Code Block |
---|
translation* will match 'translation', 'translations', 'translation-based' etc. |
Info |
---|
Starting patterns with * may impact search performance. If the search takes too long, consider alternative approaches. |