aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRado <r.hampartsumyan@viscomp.bg>2024-06-20 17:40:05 +0300
committerLouis Pilfold <louis@lpil.uk>2024-06-23 13:37:27 +0100
commit111150c30eb4d7ad03b8fb8e09bbf59d73d08bda (patch)
tree3212ba31b8350663f4d73e8b29e37a8322cf0793 /src
parentf86ab943e6326c8712314efcc906947fc3fe2ef4 (diff)
downloadgleam_stdlib-111150c30eb4d7ad03b8fb8e09bbf59d73d08bda.tar.gz
gleam_stdlib-111150c30eb4d7ad03b8fb8e09bbf59d73d08bda.zip
Fix regex.replace documentation
Diffstat (limited to 'src')
-rw-r--r--src/gleam/regex.gleam4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gleam/regex.gleam b/src/gleam/regex.gleam
index 4fc1864..0b95922 100644
--- a/src/gleam/regex.gleam
+++ b/src/gleam/regex.gleam
@@ -197,13 +197,13 @@ fn do_scan(a: Regex, b: String) -> List(Match)
///
/// ```gleam
/// let assert OK(re) = regex.from_string("^https://")
-/// replace("https://example.com", each: re, with: "www.")
+/// replace(each: re, in: "https://example.com", with: "www.")
/// // -> "www.example.com"
/// ```
///
/// ```gleam
/// let assert OK(re) = regex.from_string("[, +-]")
-/// replace("a,b-c d+e", each: re, with: "/")
+/// replace(each: re, in: "a,b-c d+e", with: "/")
/// // -> "a/b/c/d/e"
/// `
pub fn replace(