Skip to content

Instantly share code, notes, and snippets.

@cheeaun
Created April 25, 2020 12:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cheeaun/ea482cb0bf09d2c84522a563fc9e1225 to your computer and use it in GitHub Desktop.
Save cheeaun/ea482cb0bf09d2c84522a563fc9e1225 to your computer and use it in GitHub Desktop.
promisified setTimeout
const pTimeout = (t) =>
new Promise((res, rej) => {
setTimeout(res, t);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment