Skip to content

tspoke/wait-sync

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

wait-sync

a simple non-blocking-yet-synchronous wait(seconds) module


Install

npm install sync-rest-client

Usage

const waitSync = require('wait-sync');

console.log(1);

// setTimeout is async - but that's ok - since
// waitSync is non-blocking
setTimeout(() => console.log(2), 1000);

waitSync(1.5); // wait 1.5 seconds - !synchronously!

console.log(3);

// outputs 1, 2, and then 3 (as expected)

Test

npm run test

Related

About

a simple synchronous "wait(seconds)" module

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%