Flickering 2D transform elements in Chrome: a simple fix

This quick post is to point out a fix to an issue I had to deal with a few weeks ago and was caused by a Chrome update. Components with absolute positioning and a 2D CSS transform started flickering when placed inside a scrollable component. A brief search online revealed several people with similar problems, but the suggested fixes were all very different. I tested several of them (including obvious changes to the z order) before finding the one that actually did the trick.

What eventually worked for me was adding an empty 3D transform to the same elements with 2D transforms:

transform:translate3d(0,0,0);

I guess the reason why this works is that it forces elements to be drawn via a different rendering / compositing path than standard 2D elements.

Comments

Deepthi said…
Wonderful Blog!!! Your post is very informative about the latest technology. Thank you for sharing the article with us.
aws Training in Bangalore
python Training in Bangalore
hadoop Training in Bangalore
angular js Training in Bangalore
bigdata analytics Training in Bangalore

Popular posts from this blog

Parallel Beam Tracing and Visualization of 200 Million Sonar Points

Parallel Gaussian Elimination Using MPI