可以用Twitter Bootstrap实现Modernizr吗? [英] Is okay to implement Modernizr with Twitter Bootstrap?

查看:122
本文介绍了可以用Twitter Bootstrap实现Modernizr吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用Twitter Bootstrap实现Modernizr是否可以?

Is it OK to implement Modernizr with Twitter Bootstrap?

我目前正在使用带有Google的html5shiv的Bootstrap,我想知道我是否可以使用Modernizr或者是它只是为了让老版IE浏览器激活HTML5元素而过度杀伤?

I'm currently using Bootstrap with Google's html5shiv and I wanted to know if I can use Modernizr instead or is it overkill just to get HTML5 elements activated for older IE browsers?

提前致谢

推荐答案

Modernizr是一个测试套件,它通过应用于body标签的类添加特征检测。它包括HTML5Shi(v | m)以添加较旧的浏览器兼容性。你不需要Modernizr来在旧浏览器中设置新标签的样式。

Modernizr is a test suite that adds feature detection via classes applied to the body tag. It includes HTML5Shi(v|m) to add older browser compatibility. You don't need Modernizr just to style new tags in older browsers.

这就是说,可以将Modernizr与Twitter Bootstrap一起包含。您甚至可以在 Initializr 中包含Bootstrap和Modernizr自动生成的H5BP模板。

That said, it is OK to include Modernizr with Twitter Bootstrap. You can even get an auto-generated H5BP template with Bootstrap and Modernizr included at Initializr.

这篇关于可以用Twitter Bootstrap实现Modernizr吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆