css-element-queries icon indicating copy to clipboard operation
css-element-queries copied to clipboard

Running Element queries on Codepen

Open dariuszsikorski opened this issue 10 years ago • 1 comments
trafficstars

I'm trying to test element query on Codepen, but for some reason the basic example is not working Here's the code:

http://codepen.io/antraxis/pen/RNQxrz?editors=110

dariuszsikorski avatar Feb 14 '15 13:02 dariuszsikorski

Three notes

  1. The scripts you are trying to load won't execute – Error: "Refused to execute script from ... because its MIME type ('text/plain') is not executable, and strict MIME type checking is enabled."
  2. You should always use the ~= selector https://github.com/marcj/css-element-queries/issues/28#issuecomment-67327416
  3. As mentioned in the comment the min/max values are all added to the attribute – why you should reorder your CSS to make it work

I've forked your pen with a compressed inline version of the two scripts here: http://codepen.io/jakob-e/pen/azqqqO

jakob-e avatar Feb 14 '15 18:02 jakob-e