Disable automatic filling of v-input in element



In the password modification function, disable thev-inputAutomatic filling function of
The normal conditions are as follows:

Disable automatic filling of v-input in element

requirement analysis

Let’s check whether there is a corresponding solution on the official website of element. Enter the input module, and there are corresponding attribute settings in the attribute list

Disable automatic filling of v-input in element

The above attribute is for the originalinputInput box, below isv-inputThe properties used by the input box
At this point, we find that the default value isoffAt this point, the problem appears: clearly the default setting is disabled, how can this password input prompt box still appear?


First of all, let’s invite Du Niang to see what solutions the big guys on the Internet have
Finally, the following solutions are put forward
1. Set auto fill properties:


2. Inv-inputAdd a duplicate before the boxv-inputBox, then setz-indexAnddisplay:noneHide it

After trying one by one, the above methods have no effect here

However, the result is the most important. Our requirement is that we don’t need this password to automatically fill the prompt box. At this time, we can change a solution: in trial and error, we can find thatv-inputOftypeProperties are set totextTime , There will be no such prompt box . here , We only need to fill in the password into ciphertext format .

We can visit the CSS website(css-infos.net/property/-webkit-text…)Property found for processing content in

Disable automatic filling of v-input in element
Then, we test the effect:

<el-input v-model="original_pass" class="no-autofill-pwd" type="text" />


.no-autofill-pwd {
  /deep/ .el-input__inner {
    -webkit-text-security: disc !important;

results of enforcement :

Disable automatic filling of v-input in element

thus , Disable V in element – Input auto fill requirement is completed .


Sometimes the most important thing to knock code is thinking. Unfortunately, the root cause of the automatic filling of the input box has not been found. If you know, you are welcome to analyze it in the comments area^-^


This work adoptsCC agreementReprint must indicate the author and the link of this article

Recommended Today

Review of SQL Sever basic command

catalogue preface Installation of virtual machine Commands and operations Basic command syntax Case sensitive SQL keyword and function name Column and Index Names alias Too long to see? Space Database connection Connection of SSMS Connection of command line Database operation establish delete constraint integrity constraint Common constraints NOT NULL UNIQUE PRIMARY KEY FOREIGN KEY DEFAULT […]