Is it possible to show an element just before entering a long running sync process? <p>This is a very simple use case. Show an element (a loader), run some heavy calculations that eat up the thread and hide the loader when done. I am unable to get the loader to actually show up prior to starting the long running process. It ends up showing and hiding after the long running process. Is adding css classes an async process?</p> <p>See my jsbin here:</p> <p><a href="http://jsbin.com/voreximapewo/12/edit?html,css,js,output" rel="nofollow">http://jsbin.com/voreximapewo/12/edit?html,css,js,output</a></p>