0

I can <link> a stylesheet with media parameter like this:

<link rel="stylesheet" href="retina.css" media="(min-resolution: 2dppx)">

But if I use images inlined with data-uri in retina.css the file will be large. I do not want to load this extra megabyte when it's not needed.

So my question is simple: will it load if media will not match? (min-resolution is less than 2dppx for this case.)

And if it will be loaded anyway, is there any js library to load it only on media match?

  • possible duplicate [When using @media queries, does a phone load non-relevent queries and images?](http://stackoverflow.com/questions/16657159/when-using-media-queries-does-a-phone-load-non-relevent-queries-and-images) –  Aug 20 '14 at 15:30
  • @lkmhr very similar to my question but not exactly I want to test. I want to test not `css` content but `html` content loading. – Даниил Пронин Aug 22 '14 at 01:44

0 Answers0