Skip to content

Commit e32efd8

Browse files
Fix typo in $replace
1 parent 989affb commit e32efd8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

website/versioned_docs/version-1.7.0/string-functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ If `str` is not specified, then the context value is used as the value of `str`.
206206

207207
The `pattern` parameter can either be a string or a regular expression (regex). If it is a string, it specifies the substring(s) within `str` which should be replaced. If it is a regex, its is used to find .
208208

209-
The `replacement` parameter can either be a string or a function. If it is a string, it specifies the sequence of characters that replace the substring(s) that are matched by `pattern`. If `pattern` is a regex, then the `replacement` string can refer to the characters that were matched by the regex as well as any of the captured groups using a `S` followed by a number `N`:
209+
The `replacement` parameter can either be a string or a function. If it is a string, it specifies the sequence of characters that replace the substring(s) that are matched by `pattern`. If `pattern` is a regex, then the `replacement` string can refer to the characters that were matched by the regex as well as any of the captured groups using a `$` followed by a number `N`:
210210

211211
- If `N = 0`, then it is replaced by substring matched by the regex as a whole.
212212
- If `N > 0`, then it is replaced by the substring captured by the Nth parenthesised group in the regex.

0 commit comments

Comments
 (0)