Skip to content
JS
Package

heap-js

Efficient Binary heap (priority queue, binary tree) data structure for JavaScript / TypeScript. Includes JavaScript methods, Python's heapq module methods, and Java's PriorityQueue methods.

v2.7.1, 30 Sept 2025BSD-3-ClauseESM + CommonJSTypes: BundledTypeScript tooling
$ npm install heap-js

Key numbers

As of 25 Sept 2026
Weekly downloads
6.3m
+223% over 12 months
Gzip bundle size
-
No Bundlephobia data
Dependencies
0
Direct, from package.json
Last release
11 months ago
v2.7.1
GitHub stars
167
12 forks
Open issues / PRs
3 / 1
Contributors
-
Commits, last 52 weeks
12

Downloads

Last week 2026-09-15 to 2026-09-21
02.5m5m7.5m10mSept 2025Mar 2026Sept 2026High 8.8m (25 Aug 2026)Low 1.4m (23 Dec 2025)
Weekly npm downloads, one point per week, weeks starting 23 Sept 2025 to 15 Sept 2026. The y axis starts at zero.

6,260,189 downloads last week, 31,473,471 in the last month. The 12-month change of +223% compares the average of the last 4 weeks with the first 4 weeks of the series.

Releases, last 12 months
124 in total
Latest version
2.7.1, 30 Sept 202511 months ago
First published
26 Jul 2017
Last push to GitHub
9 Jan 2026258 days before the snapshot
Repository archived
No
Open issues
3
Open pull requests
1
Commits, last 52 weeks
12
Dependents on npm
65

Major versions

  1. v2 first release 2.0.0, 2 May 2020
  2. v1 first release 1.1.0, 26 Jul 2017

Recent releases

VersionPublished
2.7.130 Sept 2025
2.6.028 Dec 2024
2.5.01 Mar 2024
2.3.024 May 2023
2.2.010 May 2022
2.1.612 Jul 2021
2.1.526 Mar 2021
2.1.418 Dec 2020
2.1.323 Nov 2020
2.1.21 Sept 2020
2.1.128 May 2020
2.1.028 May 2020
2.0.02 May 2020
1.5.230 Mar 2020
Module format
ESM + CommonJSFrom package.json type, main and exports fields
TypeScript types
Bundled
Node.js engine range
>=10.0.0
Runtimes
-
Unpacked size (npm)
218 kB
Dependencies (0)
None
npm install heap-js
  • jsDelivrhttps://cdn.jsdelivr.net/npm/heap-js@2.7.1/
  • unpkghttps://unpkg.com/heap-js@2.7.1/
  • esm.shhttps://esm.sh/heap-js@2.7.1
PackageWeekly downloadsGzipLast releaseModuleComparison
bun-types11.4m-19 days ago--
grammy3.8m-29 days agoCommonJS-
@clickhouse/client2.3m-2 months agoCommonJS-
inversify1.9m-2 months agoESM only-
@inversifyjs/core1.1m-2 months agoESM only-
@inversifyjs/reflect-metadata-utils1.1m-6 months agoESM only-
@inversifyjs/common1.1m-6 months agoESM only-
junit-report-builder950.2k-5 months agoESM + CommonJS-
Sources: npm registry, npm downloads API, GitHub API. Data fetched 25 Sept 2026.

Indexability: Indexed.