@mermaid-editor-sdk/headless / addState
Function: addState()
addState(
source,requestedId?):string
Defined in: source/state-mutations.ts:370
Adds a state, generating an available ID when omitted.
Parameters
| Parameter | Type | Description |
|---|---|---|
source | string | Mermaid source to inspect or update. |
requestedId? | string | Optional state identifier; one is generated when omitted. |
Returns
string