During the project, when a user is created in the system, the browser will automatically fill in the account and password. The problem is solved as follows:

1. Add autoComplete = “new-password” to components that don’t need to be filled



But this only works with Chrome, so another way was found.


2. Add the following input box before the user input box, and set the style to hide the effect to save the filled user name and password.

<input type="text" name="hide_name" value="Whatever" style="position: absolute; z-index: -1;" disabled autocomplete = "off"/><input type="password" name="hide_pwd" value="" style="position: absolute; z-index: -1;" disabled autocomplete = "off"/>Copy the code