Relax Errors/Warnings Per File
FesterCluck opened this issue · 4 comments
@FesterCluck Do magic HTML comment pragmas (e.g. <!--bootlint disable:W017,E007 -->
) sound like a reasonable approach?
I like this idea & the comment approach. I assume it would only be possible to do this on a per-file basis, and not on a per-line/block basis, right? For example, the TSLint project allows you to disable a rule for a whole for, or just for a few lines until it is enabled again
My team's issue was resolved in finding that grunt-bootlint now supports this configuration.
@cvrebert HTML comment pragmas have been a great means of accomplishing this in other packages. Even if extended functionality is needed later, comment pragmas would make the frameworks at least as usable as other linters.
@chrismbarr Generally the approach @cvrebert describes utilizes start and end tags, therefore applying to it's content.
I assume it would only be possible to do this on a per-file basis, and not on a per-line/block basis, right?
Per-line basis wouldn't work for the in-browser version since source location info isn't preserved by the DOM.
Per-block is probably possible, but a little tricky.
Patches welcomed for either a per-file or per-block approach.