Regex To Match Anything Before The First Parenthesis

A regular expression To match everything until meeting the first parenthesis in the string.

/^[^\(]+/g

Matches:

  • I Like (RegexPattern)
  • I Like (RegexPattern

Non-matches:

  • (RegexPattern) I Like
  • (RegexPattern) I Like (RegexPattern)
  • [pattern]

See Also: