OGE logoOGE

Validation

A bpmnlint-style rule engine runs inside @oge-ui/bpmn-engine: missing start or end events, disconnected and unreachable nodes, gateways that neither fork nor join, exclusive-gateway flows without a condition, implicit splits and joins, missing labels, duplicate ids, sub-processes without a start event, message flows inside one pool and detached boundary events. Turn on live linting for badges and a problems panel, add your own rules, or call validate() — the same pure functions run on a server or in CI.

lint lintRules problems panel validate()

Live validation

[lint]="true" re-validates after every change. Offending shapes, pools and flows get a severity badge — the badge is aria-hidden and the problem text is appended to the element's accessible name instead — and the header grows a Problems toggle with the count. The problems panel lists every issue, errors first; click or Enter on a row selects the element and pans it into view. Fix the gateway conditions in the properties panel and watch the count drop.

[lint] (lintChanged) badges problems panel
Empty diagram — pick an element from the palette

Process

IdProcess_1

Custom rules & overrides

[lintRules] merges with the built-ins: a full rule ({ id, severity, check(model, context) }) is added — or replaces the built-in with the same id — and { id, severity } re-grades a built-in ('off' disables it). Here a custom info rule asks for documentation on user and service tasks, and the label rule is downgraded to info.

[lintRules] OgeBpmnLintRule severity: off
Empty diagram — pick an element from the palette

Process

IdProcess_1

validate() & headless checks

validate() runs the effective rules on demand and returns OgeBpmnLintIssue[] — no live linting needed. The engine function behind it, lintBpmnDiagram(model, rules?), takes any model from readBpmnXml(), so the same checks gate a save endpoint or a CI job over stored diagrams.

validate() lintBpmnDiagram CI
Empty diagram — pick an element from the palette

Process

IdProcess_1

0 issue(s)