Does a for loop in JavaScript try to run all iterations in the same frame, or does it wait till previous iteration finishes? -


say have for loop in javascript:

for(var i=0; i<100000; i++){     // ... } 

if run heavy code within loop, attempt cram 100,000 iterations single frame, or extend operation on multiple milliseconds if needed?

i believe question you're answered going best answered reading documentation javascript concurrency model.

in brief, however: no other javascript preempt loop while executing.


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -