This linter plugin for SublimeLinter provides an interface to csslint.
It will be used with files that have the "CSS" syntax, or within <style>
tags in HTML files.
SublimeLinter must be installed in order to use this plugin.
Please use Package Control to install the linter plugin.
Before installing this plugin, ensure that csslint
(version 0.10.0 or later) is installed on your system.
To install csslint
, do the following:
-
Install
csslint
by typing the following in a terminal:npm install -g csslint
-
If you are using
nvm
andzsh
, ensure that the line to loadnvm
is in.zshenv
and not.zshrc
.
Please make sure that the path to csslint
is available to SublimeLinter.
The docs cover troubleshooting PATH configuration.
- SublimeLinter settings: http://sublimelinter.com/en/latest/settings.html
- Linter settings: http://sublimelinter.com/en/latest/linter_settings.html
Additional SublimeLinter-csslint settings:
Setting | Description |
---|---|
errors | A comma-separated list of rules to include as errors |
warnings | A comma-separated list of rules to include as warnings |
ignore | A comma-separated list of rules to ignore |
To get a list of the available rule names, execute csslint --list-rules
from a terminal.
You may also use any of the csslint
configuration options, including .csslintrc
files and embedded rules. Please see the csslint documentation for more information.