Skip to content

Commit

Permalink
docs: tweak up usage examples
Browse files Browse the repository at this point in the history
  • Loading branch information
antongolub committed Apr 3, 2023
1 parent 43e0360 commit 5be06ba
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
[![Maintainability](https://api.codeclimate.com/v1/badges/48b31cd38b905b729beb/maintainability)](https://codeclimate.com/github/semrel-extra/topo/maintainability)
[![Test Coverage](https://api.codeclimate.com/v1/badges/48b31cd38b905b729beb/test_coverage)](https://codeclimate.com/github/semrel-extra/topo/test_coverage)

Helper to resolve monorepo dependencies graph by workspaces
Helper to resolve monorepo dependencies graph by package workspaces

## Install
```shell
Expand Down Expand Up @@ -69,6 +69,8 @@ const gpaph = topo({
### `traverseDeps()`
Iterates up to the pkg deps graph.
```ts
import {topo, traverseDeps} from '@semrel-extra/topo'

const {packages} = topo({
workspaces: ['packages/*'],
cwd: '/path/to/project/root'
Expand All @@ -84,6 +86,8 @@ await traverseDeps({packages, pkg, cb})
### `traverseQueue()`
Iterates over the queue of packages in the order of their dependencies.
```ts
import {topo, traverseQueue} from '@semrel-extra/topo'

const {queue, prev} = await topo({
workspaces: ['packages/*'],
cwd: '/path/to/project/root'
Expand Down

0 comments on commit 5be06ba

Please sign in to comment.