Modernizr如何做边界半径 [英] Modernizr How to do border-radius

查看:92
本文介绍了Modernizr如何做边界半径的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您能否使我对Modernizr有所了解.

Could you please make me little bit clear about Modernizr.

如果我使用某个功能(例如border-radius),并且使用较旧的浏览器运行该功能.现代化程序将自动向页面添加CSS还是我应该编写代码以使控件呈现为具有边框的外观?如果第二种情况是正确的,那么为什么我应该使用Modernizr?

If I use a feature (say, border-radius) and I run it using an older browser. Will the modernizer automatically add css to the page OR should I write code to render the control to view like having borders. If the second case is true, then WHY should I use Modernizr?

推荐答案

Modernizr主要为您提供测试HTML5支持的方法,然后针对缺少的内容加载垫片,以便您可以按照一种现代标准进行编码.它不会更新浏览器的本机行为.因此,对于CSS,虽然可以检测到您的浏览器是否支持边框半径,但是并没有找到模拟这种支持的方法.

Modernizr gives you mostly ways to test for HTML5 support, and then load in shims for what you're missing so that you can code to one, modern standard. It doesn't update the browser's native behaviors. So for CSS, while it detects whether or not your browser supports border radius, it doesn't figure out a way to emulate that support.

但是,它允许您决定加载一些东西来支持它们,例如 css3 pie .

It would however allow you to decide to load in something to support them like css3 pie.

这篇关于Modernizr如何做边界半径的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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