I need help to implement Modernizr.
I have posted a test at http://www.craigwebbart.com/mmw/modernizr-test.htm
The scripts that I want Modernizr to load are
css3-multi-column.js
respond.min.js
selectivizr-min.js
They are also commented-out at the bottom of the Test HTML.
I can see that jQuery and Modernizr are loading. I can see that the yep/nope JavaScript that I created is not working. Is it because these polyfills are not needed in my browser? The code appears to have a parsing error but I don't know why.
I also do not know if these are the appropriate tests to load the polyfills as needed or if they are well-formed.
Here is the yep/nope test script that I made. Please help me to improve this script and point out any other errors that you see. Also I am interested to learn of any resource that lists unified data for
modernizr test / polyfill / yep/nope test script:
Code:<script type="text/javascript"> // Give Modernizr.load a string, an object, or an array of strings and objects Modernizr.load([ // Presentational polyfills { // Logical list of things we would normally need test : Modernizr.csscolumns(columnCount), // Modernizr.load loads css and javascript by default nope : ['js/master-scripts/css3-multi-column.js'] }, test : Modernizr.mq('@media only screen and (width)'), nope : ['js/master-scripts/respond.min.js'] }, test : Modernizr.generatedcontent(), nope : ['js/master-scripts/respond.min.js'] } ); </script>
THANKS!


Reply With Quote

Bookmarks