The code that you wind up with is so long that it is hard to read for anyone, whether or not you know regular expressions. I'll never remember what all of the things are called. Anyone who knows regular expressions will find the regular expression readable. Anyone who doesn't is likely to find both relatively similar in effort to learn.
The only tool you need for maintainable regular expressions is the x modifier. That lets you break it up with whitespace and add comments. Here is a real example in code that I wrote for a tool used by people who don't know regular expressions. (This is Python that is parsing out the contents of various arrays in a bash script.)
# This match will pull those out into an array of pairs
# representing an array name and the inside of the parens::
#
# [('sqlFiles', ' "foo"
# "bar"
# "baz" '), ...]
#
#
match_pairs = re.findall(
"""(?xs) # x turns on verbose expressions (allowing these comments)
# s says . matches everything (including newlines)
( \w+ ) # Capture the name of the list
\s* = \s* # spaces = spaces
\( # find open paren
( # Capture it.
(?: # nested non-capturing pattern
\s+ # whitespace
| # or
".*?" # " with as few characters as possible then "
)* # non-capturing pattern repeats 0 or more times.
) # end capture
\) # Closing paren
""", contents)
If you know regular expressions, the comments are superfluous, though breaking up the expression does make it easier to read. If you don't know regular expressions, you should be able to figure out what the code is trying to do and how it does it.How you specify that modifier varies heavily by language. So, for example, in Perl you end your expression with /x. In Python you have to start your regular expression with (?x). In Postgres you pass a third argument with 'x' in it. Sadly, JavaScript does not support it. (Big mistake.)