Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Modernizr does not add functionality to the browser; it merely detects whether the browser supports certain functionality, and therefore allows your site to determine whether it needs to use a polyfill hack for that feature.</p> <p>Therefore you would use Modernizr to find out whether you need to use Respond.js or not.</p> <p>The Modernizr web site does include <a href="https://github.com/Modernizr/Modernizr/wiki/HTML5-Cross-Browser-Polyfills" rel="nofollow">a page which lists all the polyfill hacks that they know of</a>, so if you're not happy with Respond.js, you could try looking here to see what alternatives are available. Looking at the page, I see there are a few others listed in the "Media Queries" section, so you could try them.</p> <p>However, I will say that Respond.js does seem to be the one script which is currently recommended for this kind of thing. I haven't tried the others listed, so I can't compare them, but I can say that Respond.js works the way it does for a good reason.</p> <p>The reason that Respond.js has these complex cross-domain issues is that the only way for it to work with browsers that don't understand media queries is to load the whole stylesheet again and process it using Javascript. But the browser's security model doesn't like you doing that sort of thing with remotely loaded scripts.</p> <p>As I say, I haven't worked with any of the alternative scripts, but my guess is that they'd suffer from similar issues, due to the way they'd need to work in order to get media queries working on a browser that doesn't support them.</p> <p>The easiest way to deal with this is simply to put the respond.js script into the same domain as the rest of your site rather than loading it from a separate domain. This completely bypasses any need to deal with the CDN issue at all.</p> <p>Hope that helps.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload