I'm just a noob when it comes to regexp. I know Perl is amazing with regexp and I don't know much Perl. Recently started learning JavaScript and came across regex for validating user inputs... haven't used them much.
How does JavaScript regexp compare with Perl regexp? Similarities and differences?
Can all regexp(s) written in JS be used in Perl and vice-versa?
Similar syntax?
From ECMAScript 2018 onwards, many of JavaScript's regex deficiencies have been fixed.
/s
) flag.What is still missing:
++
/*+
/?+
or atomic groups (?>...)
).Other than that, the basic regex syntax is very similar in both flavors.
This comparison
will answer all your queries.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With