1.1.0 • Published 4 years ago

random-graph-generator v1.1.0

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

Random Graph Generator

A utility functon that generates a graph around supplied nodes, given parameters like maxWidth and edgeProbability. 🤞

Usage

const generateGraph = require('random-graph-generator');

const nodes = [
    '1',
    '2',
    '3',
    '4',
    '5'
];

generateGraph(nodes, { maxWidth: 2, edgeProbabilty: 0.3 });

Have fun!