From d01f4f53cd38fa558d74698163229635db0e352e Mon Sep 17 00:00:00 2001 From: eddiemachado Date: Fri, 23 Sep 2011 18:13:57 -0500 Subject: [PATCH] added sample Modernizr test --- library/js/scripts.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/library/js/scripts.js b/library/js/scripts.js index ba5981011..1fc0fdd80 100755 --- a/library/js/scripts.js +++ b/library/js/scripts.js @@ -9,6 +9,16 @@ slow the page load. */ +// Modernizr.load loading the right scripts only if you need them +Modernizr.load([ + { + // Let's see if we need to load selectivizr + test : Modernizr.borderradius, + // Modernizr.load loads selectivizr for IE6-8 + nope : ['selectivizr-min.js'] + } +]); + /* imgsizer (flexible images for fluid sites) */ var imgSizer={Config:{imgCache:[],spacer:"/path/to/your/spacer.gif"},collate:function(aScope){var isOldIE=(document.all&&!window.opera&&!window.XDomainRequest)?1:0;if(isOldIE&&document.getElementsByTagName){var c=imgSizer;var imgCache=c.Config.imgCache;var images=(aScope&&aScope.length)?aScope:document.getElementsByTagName("img");for(var i=0;i