I am developing a web application that needs to create and evaluate many arrays at startup. I would like to show the download page while this is happening, and maybe play a little with the css animation, but it seems that the CSS animation will hang while javascript is running. I already have a loading panel that updates on key processing events, but I would like to use css transitions to smooth it out a bit.
I was wondering if there is a way to allow something to come to life during javascript execution?
I know that I can give control to the browser from time to time to keep it updated, but I find it stupid that calculating something in the background using javascript will just freeze the whole interface.
EDIT: Here is a stupid example of what I'm talking about: http://jsfiddle.net/YWefx/13/ If you turn off css transitions, the panel is updated at each iteration, but if you turn it on, the transition will happen only at the very end. Thus, I have to either wait 400 ms between each cycle, losing 4 seconds, doing nothing but animations, having smooth animation at the end (losing the benefits of displaying a progress bar) or not animating the panel.
source share