Detect IE 10 and IE 11 with CSS

For Internet Explorer 9 and earlier version, we were able to apply CSS with conditional comments in our HTML, but since IE 10, this solution is not working anymore. So, what to do when you want to apply specific CSS for just Internet Explorer 10 and 11?

Keyfer Mathewson from Paper Leaf found a specific CSS media query only supported by this 2 versions of IE : -ms-high-contrast. This way, by setting this media query as a condition as true (active) or false (none), we can apply any CSS for only IE 10 and IE 11:

Source : https://paper-leaf.com/blog/2014/09/targeting-ie-10-11-browsers-css/