Simpler example for a regex (#2345)

This commit is contained in:
KillTheMule 2023-10-10 12:50:39 +02:00 committed by GitHub
parent 0f24990579
commit d1a702f3fd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -827,14 +827,13 @@ impl Repr for EcoString {
///
/// # Example
/// ```example
/// // Works with string methods.
/// #"a,b;c".split(regex("[,;]"))
///
/// // Works with show rules.
/// #show regex("\d+"): set text(red)
///
/// The numbers 1 to 10.
///
/// // Works with string methods.
/// #("a,b;c"
/// .split(regex("[,;]")))
/// ```
#[ty(scope)]
#[derive(Debug, Clone)]