@mermaid-editor-sdk/headless


@mermaid-editor-sdk/headless / setStateTransition

Function: setStateTransition()

setStateTransition(source, transition, patch): string

Defined in: source/state-mutations.ts:472

Updates one state transition.

Parameters

ParameterTypeDescription
sourcestringMermaid source to inspect or update.
transitionPick<StateTransition, "source" | "target" | "occurrence">Transition identified by source, target, and occurrence.
patchPartial<Pick<StateTransition, "source" | "target" | "label">>Properties to apply to the element.

Returns

string