Getting started with Concurrent Tasks is super easy. The practical nomenclature and the simplicity of it’s API is the true power behind it.
Concurrent Tasks is available to install directly via NPM.
npm i concurrent-tasks
yarn add concurrent-tasks
pnpm add concurrent-tasks
<script src="https://cdn.jsdelivr.net/npm/concurrent-tasks/umd/concurrent-tasks.min.js" type="text/javascript"></script>
bun install concurrent-tasks
import { TaskRunner } from "https://cdn.jsdelivr.net/npm/concurrent-tasks/src/index.ts";
import { TaskRunner } from "concurrent-tasks"; const runner = new TaskRunner(); function generateTasks() { const tasks = []; let count = 1000; while (count) { tasks.push((done) => { setTimeout(() => { done(); }, Math.random() * 1000); }); count--; } return tasks;} runner.addMultiple(generateTasks());