https://github.com/emkay/mkgraph
Graphs!
https://github.com/emkay/mkgraph
bfs dfs edges graph vertices
Last synced: about 1 year ago
JSON representation
Graphs!
- Host: GitHub
- URL: https://github.com/emkay/mkgraph
- Owner: emkay
- License: mit
- Created: 2017-05-14T03:00:01.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-06-03T03:32:39.000Z (about 9 years ago)
- Last Synced: 2025-06-13T02:07:39.708Z (about 1 year ago)
- Topics: bfs, dfs, edges, graph, vertices
- Language: JavaScript
- Size: 43 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# mkgraph
A tiny module for having fun with graphs.
## Install
`npm i mkgraph`
## Usage
```javascript
const {Graph, Node} = require('mkgraph')
const g = new Graph()
g.add('a')
g.add('b')
g.add('c')
g.drawEdge('a', 'b')
g.drawEdge('b', 'c')
g.shortestPath('a', 'c') // ['a', 'b', 'c']
```
## [API](https://github.com/emkay/mkgraph/blob/master/API.md)
## [Code of Conduct](https://github.com/emkay/mkgraph/blob/master/CODE_OF_CONDUCT.md)
## [Contributing](https://github.com/emkay/mkgraph/blob/master/CONTRIBUTING.md)