CSS性能问题 [英] CSS Performance issues
本文介绍了CSS性能问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
样式表(CSS)的哪些方面可能导致网站性能低下?
Sesh
解决方案
CSS?不是那么多,它是相当紧张,但在旧的(像第4代)浏览器,我看到的问题:
-
*
选择器 - 使用
继承
很多 - 加载大量外部资源(图片,其他CSS文档)
- 应用大量的内容您可以调用
div div
之类的非锚定选择器基本上,级联或级联很多。
What are the aspects of style sheets (CSS) that can lead to poor performance of web sites? Anything that can really choke up the CPU?
thanks in advance.
Sesh
解决方案
CSS? Not so much it's pretty tight, but on older (like gen 4) browsers I've seen problems with:
- doing too much on the
*
selector - using
inherit
a lot - using the IE expression value abusively
- loading a lot of external resources (images, other CSS docs)
- applying a lot of what you might call unanchored selectors like
div div
Basically anything which would be difficult to cascade through or would cascade a lot.
这篇关于CSS性能问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文