Created
January 27, 2021 15:53
-
-
Save samthomson/02c9ba278b3de3161ae49aee240a7c70 to your computer and use it in GitHub Desktop.
returns a promise that delays a certain number of milliseconds based on provided parameter
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
const sleep = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment