I searched a lot but I did not found an appropriate answer. What I actually want is execute a method which does a lot of matrix computing it takes ca. 5sec. While this method is executed I want to display a simple please wait alert or something like this.
Is this possible with (native) javascript or not cause js is single-threaded?
setTimeoutdoes not run things in parallel. It merely allows you to queue up some work for later.