Skip to content

substringAfter

substringAfter(string, delimiter) → string · String

Return the part of a string after the first occurrence of a delimiter. Returns empty string if delimiter is not found.

  • string (required): the source string

  • delimiter (required): the delimiter to search for

utlx
substringAfter("user@example.com", "@")  // "example.com"
substringAfter("no-delimiter", "@")      // "" (not found — returns empty)

Also: substringAfterLast("a.b.c.d", ".") returns "d".

Released under AGPL-3.0.