Is there a way to change how much time it takes for a password to become dots? [closed]

I’m not looking for a way to do this in pure HTML, but I want a way to change password visibility with JavaScript. I don’t just want a show/hide password button, but instead a way to hide a character or the whole field when I want to, instead of relying on the built in password fields methods.