Releases: hostnet/css-sniffer
Rulesets, multiple files and CI support
With the release of 2.0.0 we provide a more robust and streamlined tool.
With this version we have a made the sniffer more in line with the php sniffer by squizelabs. With similar output, support for more flexible rulesets and better support for CI tooling.
Major changes:
- Project rulesets can now have files, directories and exclusion patterns.
- Rules can have individual exclusion patterns so you can ignore a sniff per file or directory
- Improved
console
output - Improved
json
output - Added
checkstyle
output
The hostnet/atom-css-sniffer has already been updated to support the changes. So it is recommended to update the tool before updating the sniffer.
Minor update of the tokenizer
Minor update of the tokenizer. This should bring some improvements in the way sniffs about newlines are handled.
Better backtick support
Better backtick support so the sniffer no longer craches on backtick strings.
Fixed better detection of composite selectors
Fixed better detection of composite selectors
Media query fix
Media query must be one multiple lines, regardless of amount of statements.
Empty comments and Empty lines sniffs
Added Empty comments and Empty lines sniffs to this release.
Semicolon check
Semicolon check, double semicolons will now also result in an violation.
Curly brackets placement sniff
Curly brackets placement sniff. Test cases:
.valid { color: #ffffff; }
.valid-multi {
color: #ffffff;
font-family: sans-serif;
}
.bad1 {color: #ffffff; }
.bad2 { color: #ffffff;}
.bad3 { color: #ffffff; }
.bad-multi1 { color: #ffffff; font-family: sans-serif; }
.bad-multi2 {
color: #ffffff;
}
.ignore {}
Fixed false positive for class selector that contains generator
Fixed false positive for class selector that contains generator
Better handling of tokenizer errors
Better handling of tokenizer errors