Always returns stylelintError with boolean values #3041
Description
Describe the issue. Is it a bug or a feature request (new rule, new option, etc.)?
A bug, maybe. It is a question about internal implementations.
Which rule, if any, is this issue related to?
Not related to a certain rule.
What CSS is needed to reproduce this issue?
Not related to CSS codes.
What stylelint configuration is needed to reproduce this issue?
In fact, it doesn't matter.
const rules = {
'block-no-empty': true,
'declaration-block-no-duplicate-properties': true,
indentation: 2
}
Which version of stylelint are you using?
8.0.0
How are you running stylelint: CLI, PostCSS plugin, Node API?
Node API.
stylelint
.lint({
files: [fixture],
syntax: 'scss',
config: {
processors: [processor], // styled-components/stylelint-processor-styled-components
rules
}
})
.then(result => {
data = result
done()
})
.catch(err => {
data = err
done()
})
Does your issue relate to non-standard syntax (e.g. SCSS, nesting, etc.)?
No.
What did you expect to happen?
stylelint
always returns stylelintError
with boolean values. Are there any special considerations?
What actually happened (e.g. what warnings or errors you are getting)?
undefined
if no errors exist.null
if the file is ignored. See lib/lintSource.js.true
if some rules have called the functionreport
. See /lib/utils/report.js.