I want to validate a password entered by the user for the following criteria :
Password should be at least 8 characters as min and 20 as max and should contain one number, one capitalized character, and one special character within this only ,./<>?;':"[]{}\|!@#$%^&*(-=_+ (.
For it I used following regular expression :
Password:
['', [Validators.pattern('(?=.[a-z])(?=.[A-Z])(?=.[0-9])(?=.[$@$!%#?^&+=,.-])[A-Za-z\d$@$!%#?^&+=,.-].{8,}')]]``