ko-sleep
A promise wrapper for `setTimeout`
Last updated 3 years ago by alsotang .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install ko-sleep 
SYNC missed versions from official npm registry.

ko-sleep

Build Status

A promise wrapper for setTimeout

usage

sleep(time: number | string): Promise<void>

time - millisecond number, or '1s' which https://www.npmjs.com/package/ms support

example

import sleep from 'ko-sleep'

await sleep(3 * 1000)
await sleep('3s')

license

MIT

Current Tags

  • 1.1.4                                ...           latest (3 years ago)

9 Versions

  • 1.1.4                                ...           3 years ago
  • 1.1.3                                ...           3 years ago
  • 1.1.2                                ...           3 years ago
  • 1.1.1                                ...           3 years ago
  • 1.1.0                                ...           3 years ago
  • 1.0.3                                ...           7 years ago
  • 1.0.2                                ...           9 years ago
  • 1.0.1                                ...           9 years ago
  • 1.0.0                                ...           9 years ago
Maintainers (1)
Downloads
Total 0
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (1)
Dev Dependencies (3)
Dependents (4)

© 2010 - cnpmjs.org x YWFE | Home | YWFE