@@ -70,9 +70,9 @@ Terminology:
70
70
Most of the regex constructs accept a regex sequence as their argument.
71
71
72
72
Examples of sequences:
73
+ - single element (construct): ` capture('abc') `
74
+ - single element (string): ` 'Hello' `
73
75
- array of elements: ` ['USD', oneOrMore(digit)] `
74
- - single construct: ` capture('abc') `
75
- - single string: ` 'Hello' `
76
76
77
77
Regex constructs can be composed into a tree structure:
78
78
@@ -94,21 +94,21 @@ Comprehensive API document is available [here](./API.md).
94
94
95
95
### Regex Builders
96
96
97
- | Builder | Regex Pattern | Description |
97
+ | Builder | Regex Syntax | Description |
98
98
| ---------------------------------------- | ------------- | ----------------------------------- |
99
99
| ` buildRegExp(...) ` | ` /.../ ` | Create ` RegExp ` instance |
100
100
| ` buildRegExp(..., { ignoreCase: true }) ` | ` /.../i ` | Create ` RegExp ` instance with flags |
101
101
102
102
### Regex Constructs
103
103
104
- | Regex Construct | Regex Pattern | Notes |
104
+ | Construct | Regex Syntax | Notes |
105
105
| ------------------- | ------------- | ------------------------------- |
106
106
| ` capture(...) ` | ` (...) ` | Create a capture group |
107
107
| ` choiceOf(x, y, z) ` | ` x\|y\|z ` | Match one of provided sequences |
108
108
109
109
### Quantifiers
110
110
111
- | Regex Construct | Regex Pattern | Description |
111
+ | Quantifier | Regex Syntax | Description |
112
112
| -------------------------------- | ------------- | ------------------------------------------------- |
113
113
| ` zeroOrMore(x) ` | ` x* ` | Zero or more occurence of a pattern |
114
114
| ` oneOrMore(x) ` | ` x+ ` | One or more occurence of a pattern |
@@ -119,7 +119,7 @@ Comprehensive API document is available [here](./API.md).
119
119
120
120
### Character classes
121
121
122
- | Regex Construct | Regex Pattern | Description |
122
+ | Character class | Regex Syntax | Description |
123
123
| --------------------- | ------------- | ------------------------------------------- |
124
124
| ` any ` | ` . ` | Any character |
125
125
| ` word ` | ` \w ` | Word characters |
@@ -132,7 +132,7 @@ Comprehensive API document is available [here](./API.md).
132
132
133
133
### Anchors
134
134
135
- | Regex Construct | Regex Pattern | Description |
135
+ | Anchor | Regex Syntax | Description |
136
136
| --------------- | ------------- | ---------------------------------------------------------------- |
137
137
| ` startOfString ` | ` ^ ` | Match start of the string (or start of a line in multiline mode) |
138
138
| ` endOfString ` | ` $ ` | Match end of the string (or end of a line in multiline mode) |
0 commit comments