@arijitdn/task-repeater

1.0.3 • Public • Published

npm version code style: prettier

Task Repeater

A promise based tool which will repeat your tasks a defined amount of times

Prerequisites

This project requires NodeJS (version 8 or later) and NPM. Node and NPM are really easy to install. To make sure you have them available on your machine, try running the following command.

$ npm -v && node -v
6.4.1
v8.16.0

Table of contents

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Installation

BEFORE YOU INSTALL: please read the prerequisites

Start with cloning this repo on your local machine:

$ git clone https://github.com/arijitdn/task-repeater.git
$ cd task-repeater

To install and set up the library, run:

$ npm install @arijitdn/task-repeater

Or if you prefer using Yarn:

$ yarn add @arijitdn/task-repeater

Usage

Example 1:

const { repeatTask } = require("@arijitdn/task-repeater");

const n = 10;
function task() {
  console.log("Hello World\n");
}

repeatTask(task, n);

Example 2:

const { repeatTask } = require("@arijitdn/task-repeater");

repeatTask(() => {
  console.log("Hello World\n");
}, 10);

Built With

  • NodeJS

Authors

License

Apache 2.0 © Arijit Debnath

Package Sidebar

Install

npm i @arijitdn/task-repeater

Weekly Downloads

1

Version

1.0.3

License

Apache-2.0

Unpacked Size

3.82 kB

Total Files

3

Last publish

Collaborators

  • arijitdn