Just wondering.
We usually trim a user name in various forms in our ASP.Net application, whats the best practices for password fields.
i.e. should we remove
You can use this to alert user that password include spaces or something like that.
if (/^\s|\s$/.test(password)) { //alert('Hey Watchout'); }
Triming password is not a good practice.
Hope this helps.