What is the problem with this? I try it with Regexr and I match every test.
^[A-Z](?=\w{5,})(?=\D*\d)$/i
What is the problem with this? I try it with Regexr and I match every test.
^[A-Z](?=\w{5,})(?=\D*\d)$/i
Your regex should use two positive
lookaheads.
Don’t use the g flag with test method (you can look at the documentation on the why)