Jitendra Vyas
Jitendra Vyas

Reputation: 152807

How to hide warning and show errors only in Stylelint linting result?

Stylelint has this option "severity": "warning" to changed errors to warnings. Is it possible to hide warnings from output temporarily? because I want to fix some errors and because of lots of warnings, it takes a long time to reach to error instances

Upvotes: 3

Views: 4561

Answers (2)

choasia
choasia

Reputation: 10882

I believe you are looking for the quiet option which suppress "warnings"

https://github.com/stylelint/stylelint/blob/master/lib/cli.js#L257-L260

--quiet, -q
Only register warnings for rules with an "error"-level severity (ignore
"warning"-level).

Upvotes: 9

jeddy3
jeddy3

Reputation: 3959

I believe you have a choice:

  1. Turn off the rules using null.
  2. Write a custom formatter that does not display warnings.

Upvotes: 1

Related Questions