Sinister Beard
Sinister Beard

Reputation: 3680

Transitions run slower on first use in IE

I have an element that has transition: all .25s linear;.

It runs very slightly slower on its first use whenever the page is loaded in IE11, and thereafter works as expected. Why is this? Is there some caching of the animation? Works as expected in Chrome.

This sounds nitpicky, but it's a noticeable and annoying glitch as the elements position is effected by it, and on the slower load, you can see a background element you shouldn't be able to.

Upvotes: 0

Views: 250

Answers (1)

Kapeesh Manilal
Kapeesh Manilal

Reputation: 104

I suspect that it runs slowly the first time due to initial page load. There may be other processes running that may slow the transition down too. The second time will be smoother because resources have been cached and performance isn't hampered. I would run your site through https://developers.google.com/speed/pagespeed/?hl=en to find any render-blocking scripts that may be hampering performance.

Also see this article to identify which properties can be animated cheaply. http://www.html5rocks.com/en/tutorials/speed/high-performance-animations/

Upvotes: 1

Related Questions