Last active
March 21, 2024 21:39
-
-
Save sharjeel619/332f190aadbc8309312a54e7739960c2 to your computer and use it in GitHub Desktop.
Revisions
-
sharjeel619 revised this gist
Mar 21, 2024 . 1 changed file with 9 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,12 @@ // These examples Block UI let startTime = performance.now(); while (performance.now() - startTime < 500) { // // Do nothing for 500 ms to emulate extremely slow code } const wait = (ms) => { const start = Date.now(); let now = start; while (now - start < ms) now = Date.now(); } -
sharjeel619 created this gist
Aug 10, 2023 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,4 @@ let startTime = performance.now(); while (performance.now() - startTime < 500) { // // Do nothing for 500 ms to emulate extremely slow code }