I used the background image for the signup form and the signup process consists of several steps.
So when I return the first step other fields looks good but the autocomplete fields are white for the background and black for the color. I want to remove this for showing the original background. I thought it is because of "autocomplete" attribute. So I filled the form and input with "autocomplete"="off". But it didn't work for me. I also add the code belows
const handleFocus = () => {
emailInput.current.removeAttribute('readonly')
}
<input readonly="readonly" ref={emailInput} onFocus={handleFocus} type="text" value={value}>
It also didn't work.
I hope someone can help me with this problem.
question from:
https://stackoverflow.com/questions/65932759/how-to-turn-off-autofill-autocomplete-in-input-in-a-form 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…