Questions tagged [csslint]

csslint is a program used to parse CSS and flag syntax errors, anti-patterns, and redundant declarations.

csslint is open-source and has command-line, browser, and IDE interfaces.

79 questions
2
votes
1 answer

Is it possible to run CSSLint from WSH on Windows?

There's a CSSLint project on github. It appears to be philosophically inspired by the JSLINT/JSHINT project. It's a JavaScript program that checks the syntax of CSS files, and throws errors or warnings. There are versions for Rhino and Node. How…
Cheeso
  • 189,189
  • 101
  • 473
  • 713
2
votes
1 answer

ATOM - CSSLINT ignore ids

Is there a way to make csslint in Atom ignore "ids", so I don't get the warning "Don't use IDs in selectors"? Edit: My question was identified as a possible duplicate of "Disable warnings (ids selector) in linter-csslint on Atom?", but I mentioned…
2
votes
1 answer

SVG Circle radius with CSS

I tried to change the radius of SVG Circle with css, and it works in all major browser versions. The question is why CSS lint complaining about r property while all browsers support this just fine!?
PRAISER
  • 793
  • 7
  • 15
2
votes
1 answer

How to add ignorefiles for specific rules in stylelint config js

Hi want to ignore certain files for a specific rule in style lint config js like below 'color-named': [ 'never', { 'ignore': [ 'library/styles/**/*.css', 'components/**/styles/variable.css' ] } ], However this is not…
Rkrishn
  • 35
  • 4
2
votes
0 answers

CSS error : Name of overqualified element should be removed

Consider this css, which make all elements in form and with mask-amount class become bold: form .mask-amount { font-weight: bold; } Of course the above will not change the font weight of mask-amount elements outside form. This will not be bold…
Alireza Fattahi
  • 42,517
  • 14
  • 123
  • 173
2
votes
1 answer

How could you LINT your LESS and SCSS files in Node JS WITHOUT using grunt or gulp?

So the thing is I went through the internet and checked for available linters. Mostly all the the LESS linters available provide a command line interface or a plugin for grunt or gulp. What I really want is a simple Node Plugin which is configurable…
Akshay Khandelwal
  • 1,570
  • 11
  • 19
2
votes
2 answers

What is the purpose of this csslint error and how can I get rid of it?

I added the following CSS code to get rid of the outline that was appearing after click on a link HTML element. CSS Code: .window-leveling-btn:focus { outline: 0; } Afterwards I get the following csslint error message. I don't understand why I…
Daniel Kobe
  • 9,376
  • 15
  • 62
  • 109
2
votes
0 answers

Issue with more than two linters working on sublime 3

I'm running sublime 3084 OSX 10.10.3 and i have three tabs open, one html document, one css and one javascript file. I have linters for all three installed but whenever I open the program only the css linter (csslint) and either the html or the…
Jonathan H.
  • 939
  • 1
  • 7
  • 21
2
votes
2 answers

CSS ID's vs Classes warnings when validating in CSS Lint

I'm using XHTML (strict) to create a webpage - I cannot use HTML5 yet. When I run my CSS code through CSS Lint, I get the warning "Don't use IDs in selectors" several times. I'm not sure why I'm getting these warnings. Should I be exclusively using…
pete
  • 19
  • 2
2
votes
1 answer

How to override "Selectors should not contain IDs" rule in SublimeLinter-CSSLint?

Entering csslint --list-rules into the terminal, I see the following rule: ids Selectors should not contain IDs. So, in my SublimeLinter.sublime-settings user prefs file, I've tried setting "ids" to false, true, "none", "ignore", "exclude", and…
2540625
  • 11,022
  • 8
  • 52
  • 58
2
votes
1 answer

CSS - linter vs. beautifier inconsistency

I am using grunt-jsbeautifier to pretty-print a .css file, and grunt-contrib-csslint to check the .css file for problems. Unfortunately the beautifier seems to produce CSS which violates a linter rule. If I have this CSS: .half_circle_style…
Renny Barrett
  • 138
  • 1
  • 6
2
votes
2 answers

Getting errors in the CSS linter when using media queries

When I put the code below through the CSS Linter I get six errors. Are these bugs in the linter or the CSS? I can't see anything wrong with the CSS. I can't seem to turn off or ignore the errors either regardless of the settings. @media ( max-width:…
byronyasgur
  • 4,627
  • 13
  • 52
  • 96
2
votes
1 answer

CSS validator where you can disable error messages on per file basis

Does there exist a CSS validator where one could hint inside a file, á la jslint, what validation rules are and are not effective inside this file or a rule. I tried W3C validator csslint Neither of them offers this functionality and always lead…
Mikko Ohtamaa
  • 82,057
  • 50
  • 264
  • 435
1
vote
0 answers

Unable to fix CSSLint error "Expected RBRACE" on CSS grid rule

I'm using Stylus and Grunt with CSS Lint and am getting an error on this rule: .example grid-template-columns repeat(auto-fill, minmax(50%, 1fr)) The error I get is: >> ERROR: Expected RBRACE at line 9, col 147897. This rule looks for recoverable…
Chris_Heu
  • 119
  • 2
  • 12
1
vote
0 answers

CssLint - Unexpected token

I have this media query that, when parsed by CssLint, is giving an "unexpected token '321px'" error. Can anyone see why this is causing the error please? I can't. This is not being caused by the id selector. I've tested that by replacing it with a…
Andrew Terwiel
  • 721
  • 4
  • 10