How to disable spellcheck in form input fields
Learn, how to turn off default spelling checking behavior for form elements like (input, textarea).
Note: When you type a wrong text inside the form elements, you will see a red color underline below that words which is a browser default behavior to notify you that your typing an incorrect word.
Disabling the spellcheck
We can disable the spellcheck of an input field by setting a spellcheck
attribute to false
.
Example:
<input type="text" spellcheck="false"/>
You can also disable spell checking for an entire form, instead of a specific form field like this.
<form spellcheck="false"> <input type="text"/>
</form>
for textarea
element:
<textarea spellcheck="false"></textarea>