graph-builder
Version:
A graph builder library for modeling abstract graph structures.
23 lines (14 loc) • 578 B
Markdown
[Home](./index) > [graph-builder](./graph-builder.md) > [MutableValueGraph](./graph-builder.mutablevaluegraph.md) > [addNode](./graph-builder.mutablevaluegraph.addnode.md)
# MutableValueGraph.addNode method
Adds `node` if it is not already present.
<b>Nodes must be unique</b>, just as `Map` keys must be.
**Signature:**
```javascript
addNode(node: N): boolean;
```
**Returns:** `boolean`
`true` if the graph was modified as a result of this call
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| `node` | `N` | |