Pass lint options (rules) into CSSLint.verify() #4938
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
It is not currently possible to pass a custom CSSLInt ruleset to the
css-lintaddon. The second argument toCSSLint.verify()is theruleset, which isoptionshere:https://github.com/CSSLint/csslint/blob/a4361d4b4cdfa9f04ebe7e8e3a4d4e991e6af5c8/src/core/CSSLint.js#L166-L175
There should be parity with the the
javascript-lintaddon which passes theoptionstoJSHINT:https://github.com/codemirror/CodeMirror/blob/883fd008d29fdcaab18b50f47c248e3d112f39ed/addon/lint/javascript-lint.js#L24-L31
And similarly for the
html-lintaddon:https://github.com/codemirror/CodeMirror/blob/883fd008d29fdcaab18b50f47c248e3d112f39ed/addon/lint/html-lint.js#L30-L40
Incidentally, the
csslintrule for HTMLHint does allow you to pass in a custom ruleset, but this only workshtmlmixedmode.