How to suppress spellchecking in HTML, one statement or block of statements at a time
已回答
I'm looking for something that would suppress spell checking on a single line, or range of lines, in an HTML file. Something that would work like this:
<!-- noinspection SpellCheckingInspection -->
Not inside a script tag inside HTML, but for spelling issues in the HTML itself. Without adding words to the dictionary, without adding the whole file to an unchecked scope. Cspell for VSCode does this with comments like <!-- cspell:disable -->.
What I find totally bizarre is that I can't even find a Google match for anyone talking about this specific issue, which seems to be like it would be a pretty common need.
请先登录再写评论。
Try this:
It is not always working, unfortunately. See https://youtrack.jetbrains.com/issue/WEB-40943/HTML-suppress-SpellCheckingInspection-does-not-work
I gave that a try, unfortunately it didn't help. Thanks anyway.
May you show the code smippet where it is not working?
The full project code is here: https://github.com/kshetline/prague-clock
Created bug request for that:
WEB-55648 suppress SpellCheckingInspection is not working in HTML code
For the time being, you can disable the inspection:
I definitely don't want to disable all spellchecking everywhere. But I have added this file to a scope where the typo inspection is disabled.
It is just a workaround until the time the main issue is fixed.