Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cusspvz/await-delay
use delay/sleep/wait to async/await ES7
https://github.com/cusspvz/await-delay
async-await delay es7 promise sleep wait
Last synced: 3 months ago
JSON representation
use delay/sleep/wait to async/await ES7
- Host: GitHub
- URL: https://github.com/cusspvz/await-delay
- Owner: cusspvz
- Created: 2016-07-21T15:37:40.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2016-07-21T15:44:31.000Z (over 8 years ago)
- Last Synced: 2024-10-04T03:21:46.242Z (4 months ago)
- Topics: async-await, delay, es7, promise, sleep, wait
- Language: JavaScript
- Homepage:
- Size: 1000 Bytes
- Stars: 10
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# await-delay
use delay/sleep to async/await ES7
## Installation
```bash
npm i --save await-delay
```## Usage
```js
import delay from 'await-delay'async () => {
// Do something
// Wait for 2 seconds
await delay(2000)// Do things after the delay
}```