@ilihub/queue
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

@ilihub/queue

Queue operations implementation in TypeScript.

NPM Version NPM CodeFactor Socket Badge

Installation

# if you're using pnpm
pnpm add @ilihub/queue

# or, if you're using npm
npm install @ilihub/queue

# or, if you're using yarn
yarn add @ilihub/queue

Usage

import { Queue } from "@ilihub/queue";

const queue = new Queue();

queue.enqueue(1);
queue.enqueue(2);

queue.dequeue();

console.log(queue.peek());

console.log(queue.isEmpty());

console.log(queue.size());

Sponsors & Backers

Support the development of new open-source projects from ilihub through crowdfunding.

The core of ilihub is our crowd-funded open-source projects, licensed under the permissive MIT license. Sponsorship increases the rate of bug fixes, documentation improvements, and feature development.

Sponsors


Package Sidebar

Install

npm i @ilihub/queue

Weekly Downloads

1

Version

1.0.0

License

MIT

Unpacked Size

5.33 kB

Total Files

5

Last publish

Collaborators

  • harshraj8843