简体   繁体   English

`background-size:100%或cover`会导致javascript变慢

[英]`background-size:100% or cover` causes javascript to slow

In FF 17 : 在FF 17中:

body{
  background:  url('foo/images/flowers.jpg');
  background-size:  100%;
  background-attachment:  fixed;
}

causes the page to move slow, this means the animation and even the mouse pointer trailing across the screen. 导致页面移动缓慢,这意味着动画甚至鼠标指针都在屏幕上拖尾。

Once I remove the background image all is fine. 一旦我删除背景图像一切都很好。

To troubleshoot I removed the Base64 representation of the image and linked directly to the image as shown above. 要进行故障排除,我删除了图像的Base64表示,并直接链接到图像,如上所示。

I can continue to isolate in this manner, but I'm wondering if this is a known issue. 我可以继续以这种方式孤立,但我想知道这是否是一个已知的问题。


Isolating further it is this property causing the issue. 进一步隔离是造成这个问题的属性。

  background-size:  100%;

这似乎是background-size:100% or cover的问题background-size:100% or cover已在新FF修复的background-size:100% or cover

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM