Created
April 14, 2021 12:12
-
-
Save 0xtlt/640810511178b0893f8795df6ceee865 to your computer and use it in GitHub Desktop.
Wait function in JS
This file contains 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 characters
async function Wait(time) { | |
return new Promise(resolve => { | |
setTimeout(resolve, time); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment