Today I Learned - Rocky Kev

TIL default spellcheck in html

POSTED ON:

TAGS:

The spellcheck is a global attribute that you can use to check spelling and grammar on HTML elements such as input fields and other editable elements.

In the first element, see the 'red swiggles'?

<p contenteditable="true" spellcheck="true">
Thanks furr checkinng my speling :)</p>

This attribute is merely a hint for the browser: browsers are not required to check for spelling errors.

Typically non-editable elements are not checked for spelling errors, even if the spellcheck attribute is set to true and the browser supports spellchecking.

MDN spellcheck


Related TILs

Tagged:

TIL Gmail has a 102KB size-limit for HTML

PLACEHOLDER

TIL how Error correction works in HTML

You never get an 'Invalid Syntax' error on an HTML page. Browsers fix any invalid content and go on.

TIL what DOCTYPE means

tl;dr: DOCTYPE declaration in the first line of the HTML file, to instruct the browser to run the code in Standard mode.