Skip to content

jbarzegar/I-Shleep

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

shleep is a promise based sleep function 😴

Shleep is tiny,coming in at 183 bytes

Installation

Yarn

yarn install shleep

Npm

npm install -S shleep

Usage

import sleep from 'shleep'

// Standard promise
sleep(1000).then(/* Do stuff */)

// async await
async function yourAsyncFunction() {
  await sleep(1000)

  /* do stuff here */
}

About

A tiny promise based sleep function

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published