@pnpm/deps.graph-sequencer
TypeScript icon, indicating that this package has built-in type declarations

2.0.1 • Public • Published

@pnpm/deps.graph-sequencer

Sort items in a graph using a topological sort

Install

pnpm add @pnpm/deps.graph-sequencer

Usage

  expect(graphSequencer(new Map([
    [0, [1]],
    [1, [2]],
    [2, [3]],
    [3, [0]],
  ]), [0, 1, 2, 3])).toStrictEqual(
    {
      safe: false,
      chunks: [[0, 1, 2, 3]],
      cycles: [[0, 1, 2, 3]],
    }
  )

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i @pnpm/deps.graph-sequencer

Weekly Downloads

2,833

Version

2.0.1

License

MIT

Unpacked Size

10.6 kB

Total Files

6

Last publish

Collaborators

  • pnpmuser
  • zkochan