ie8linter icon indicating copy to clipboard operation
ie8linter copied to clipboard

Conditional Comments are ignored

Open rvock opened this issue 10 years ago • 3 comments

I have a seperate stylesheet for IE8, which I load using Conditional Comments:

<!--[if gt IE 8]><!--><link rel="stylesheet" href="static/page.css"><!--<![endif]-->
<!--[if lte IE 8]><link rel="stylesheet" href="static/page-ie.css"><![endif]-->

IE8 Linter checks page.css instead of page-ie.css

rvock avatar Feb 11 '15 12:02 rvock

The problem is that both need to be technically checked.

However, I'm considering a solution where I could be "smart" about checking for overrides. There are various problems and challenges.

Until that solution is available I'm taking the approach of "let's warn about everything just in case".

etodanik avatar Feb 11 '15 12:02 etodanik

Sorry, my first comment was not formated correctly. You could not see the conditional comments correctly. I've updated my post.

Now you can see, that I have two conditional comments. The first is only visible for IE > 8 and the second is only visible for IE <= 8. This prevents IE8 from loading the first stylesheet. So you do not need to check the first stylesheet.

rvock avatar Feb 11 '15 14:02 rvock

I see, yes - that's possible to support. I'll look into it.

etodanik avatar Feb 11 '15 14:02 etodanik