spelling-markers-003.html (798B)
1 <!DOCTYPE html> 2 <html lang="en"> 3 <meta charset="utf-8"> 4 <title>Turning off spellcheck on editing hosts while keeping them editable</title> 5 <link rel=match href="references/spelling-markers-001-ref.html"> 6 <link rel=help href="https://html.spec.whatwg.org/multipage/interaction.html#spelling-and-grammar-checking"> 7 <meta name=assert content="Spellchecking stops applying to editing hosts when the spellcheck attribute becomes false"> 8 9 <div id="test" spellcheck=true contenteditable=true>This test passes if there is no visual marker indicating the spellinnnnnggg mistake in this sentence, and fails otherwise.</div> 10 11 <script> 12 var test = document.getElementById("test"); 13 // Force spellcheck by focus and then blur 14 test.focus(); 15 test.blur(); 16 test.setAttribute("spellcheck", false); 17 </script>