Comment by bmacho
11 hours ago
> Not documented anywhere (but seems to work fine in major browsers)
Which part of it is not documented? Putting device width dependent preloading in HTTP header? MDN says that the HTTP link header works the same way as the link element, and also that the link element a has media attribute : https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/...
I could not find this hack documented or discussed anywhere, that's what I meant.
It’s not a hack, but you may find more documentation for the equivalent preload values expressed as a <link> tag. There is (near) parity between that and the HTTP Link header. The values used in the article should work in HTML as well.
> It’s not a hack
Yeah, this isn't a hack; this is what media queries were made for.
Now, this is a hack!
You had to do this to make :hover work correctly for IE6—IE8 [1]:
[1]: https://pawelgrzybek.com/internet-explorer-just-hit-the-end-...