# @dagrejs/graphlib

> A directed and undirected multi-graph library

Latest version **4.0.5** (published 2026-08-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install @dagrejs/graphlib
pnpm add @dagrejs/graphlib
yarn add @dagrejs/graphlib
bun add @dagrejs/graphlib
```

## Health

**Score 70/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; recently updated; high maintenance score; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 4.0.5 |
| Published | 2026-08-03 |
| First published | 2017-12-26 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 461.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1743 |
| Author | Chris Pettitt |
| Maintainers | cpettitt, lutzroeder, davidnewell |
| Keywords | graph, algorithms |

## Links

- npm: https://www.npmjs.com/package/@dagrejs/graphlib
- Repository: https://github.com/dagrejs/graphlib
- Homepage: https://github.com/dagrejs/graphlib#readme
- Issues: https://github.com/dagrejs/graphlib/issues
- npm.io page: https://npm.io/package/@dagrejs/graphlib

## Alternatives

- [apollo-link-http-common](https://npm.io/package/apollo-link-http-common.md) — 879.0K weekly downloads
- [react-relay](https://npm.io/package/react-relay.md) — 336.8K weekly downloads
- [relay-test-utils](https://npm.io/package/relay-test-utils.md) — 181.6K weekly downloads
- [@vendure/core](https://npm.io/package/@vendure/core.md) — 14.8K weekly downloads
- [@pnpm/deps.graph-sequencer](https://npm.io/package/@pnpm/deps.graph-sequencer.md) — 13.4K weekly downloads

## Recent versions

- 4.0.5 (latest) — 2026-08-03
- 4.0.3 — 2026-08-02
- 4.0.1 — 2026-03-08
- 3.0.4 — 2026-02-09
- 3.0.2 — 2026-01-27
- 3.0.1 — 2026-01-27
- 2.2.4 — 2024-08-15
- 2.2.3 — 2024-07-17
- 2.2.2 — 2024-04-11
- 2.2.1 — 2024-03-15
- 2.2.0 — 2024-03-12
- 2.1.13 — 2023-05-23
- 2.1.12 — 2023-03-06
- 2.1.11 — 2023-03-03
- 2.1.10 — 2023-03-03
- … 2 more at https://npm.io/package/@dagrejs/graphlib/versions

## README

> English | [中文](README_CN.md)
# Graphlib

Graphlib is a JavaScript library that provides data structures for undirected
and directed multi-graphs along with algorithms that can be used with them.

[![Build Status](https://github.com/dagrejs/graphlib/workflows/Build%20Status/badge.svg?branch=master)](https://github.com/dagrejs/graphlib/actions?query=workflow%3A%22Build+Status%22)
[![npm](https://img.shields.io/npm/v/@dagrejs/graphlib.svg)](https://www.npmjs.com/package/@dagrejs/graphlib)

To learn more [see our Wiki](https://github.com/cpettitt/graphlib/wiki).

There are 2 versions on NPM, but only [the one in the DagreJs org](https://www.npmjs.com/package/@dagrejs/graphlib) is receiving updates right now.

# License

Graphlib is licensed under the terms of the MIT License. See the [LICENSE](LICENSE) file for details.

[npm package manager]: http://npmjs.org/

---
_Source: https://npm.io/package/@dagrejs/graphlib · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
