Skip to content

117/sleep

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sleep

version status

A promise-based sleep function for Deno.

Contents

Features

  • Minimal and easy to use.
  • Can be used to await for a specified amount of time.

Install

For Deno:

$ deno add @117/sleep

Example

import { sleep } from "@117/sleep";

const work = async () => {
    console.log("please wait for 2 seconds");
    await sleep(2000);
    console.log("thanks for waiting");
};

work();

Contributing

Feel free to contribute and PR to your 💖's content.

About

A promise-based sleep function for Deno.

Topics

Resources

License

Stars

Watchers

Forks