开发者

Modernizr.load not working properly in IE8

I'm trying to load in a specific CSS stylesheet depending whether certain CSS3 features aren't supported in that browser.

The JS code I use is this:

// Modernizr feature tests
Modernizr.load({
    test: Modernizr.borderradius,
    nope: '/assets/css/border-radius.css'
});
开发者_JAVA百科

In IE8 this gives, according to the developer tools:

<link href="undefined" rel="stylesheet" type="text/css" />

Any ideas?


It seems to be a bug in Modernizr Minifier. I've encountered the same issue, but was able to fix that manually. Here are the details: https://github.com/Modernizr/Modernizr/issues/308

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜