3.28.0 • Published 9 months ago

@camunda/linting v3.28.0

Weekly downloads
-
License
MIT
Repository
github
Last release
9 months ago

@camunda/linting

CI

The BPMN linter used by the Camunda Desktop and Web Modeler. Batteries included. 🔋

Features

  • bundles bpmnlint and bpmnlint-plugin-camunda-compat
  • configures linter based on modeler:executionPlatform and modeler:executionPlatformVersion
  • creates error messages to be shown in desktop and web modeler
  • creates errors to be shown in properties panel
  • creates error overlays to be shown on canvas

Usage

import Modeler from 'bpmn-js/lib/Modeler';

import { Linter } from '@camunda/linting';

import lintingModule from '@camunda/linting/modeler';

import '@camunda/linting/assets/linting.css';

const modeler = new Modeler({
  additionalModules: [
    lintingModule
  ]
});

// configure to be used with desktop or web modeler
const linter = new Linter({
  modeler: 'web', // `desktop` or `web` modeler, defaults to `desktop`
  type: 'cloud' // `cloud` or `platform` diagrams, defaults to `cloud`
});

// lint by passing definitions
const reports = await linter.lint(definitions);

// or passing XML
const reports = await linter.lint(xml);

...

// update errors on canvas and in properties panel (requires bpmn-js-properties-panel >= 1.3.0)
modeler.get('linting').setErrors(reports);

// show error by selecting element and properties panel entry
modeler.get('linting').showError(report);

// activate and deactivate errors on canvas
modeler.get('linting').activate();
modeler.get('linting').deactivate();

Development

# install
npm i

# run tests
npm t

# run tests in watch mode
npm run test:watch

# run example
npm start

License

MIT

3.28.0

9 months ago

3.27.2

9 months ago

3.26.0

10 months ago

3.26.1

10 months ago

3.27.1

10 months ago

3.27.0

10 months ago

3.20.0

1 year ago

3.22.0

1 year ago

3.24.0

11 months ago

3.21.1

1 year ago

3.21.0

1 year ago

3.23.0

11 months ago

3.25.0

11 months ago

3.19.0

1 year ago

3.18.1

1 year ago

3.18.0

1 year ago

3.17.0

1 year ago

3.16.0

1 year ago

3.15.0

1 year ago

3.14.0

1 year ago

3.13.0

1 year ago

3.12.0

2 years ago

3.11.0

2 years ago

3.9.0

2 years ago

3.7.2

2 years ago

3.4.0

2 years ago

3.2.0

2 years ago

3.8.0

2 years ago

3.10.0

2 years ago

3.6.0

2 years ago

3.4.1

2 years ago

3.0.0

2 years ago

4.0.0-0

2 years ago

3.8.1

2 years ago

3.3.0

2 years ago

3.1.1

2 years ago

3.1.0

2 years ago

3.7.1

2 years ago

3.7.0

2 years ago

3.5.1

2 years ago

3.5.0

2 years ago

1.3.0

2 years ago

1.2.1

2 years ago

2.2.0

2 years ago

2.1.0

2 years ago

2.0.0

2 years ago

1.2.0

2 years ago

1.1.0

2 years ago

1.0.0

2 years ago

0.17.0

2 years ago

0.16.0

2 years ago

0.15.1

2 years ago

0.13.0

2 years ago

0.14.0

2 years ago

0.15.0

2 years ago

0.11.0

3 years ago

0.12.0

3 years ago

0.10.0

3 years ago

0.9.0

3 years ago

0.8.0

3 years ago

0.9.1

3 years ago

0.7.2

3 years ago

0.7.1

3 years ago

0.7.0

3 years ago

0.5.0-alpha.3

3 years ago

0.5.0-alpha.2

3 years ago

0.5.0-alpha.1

3 years ago

0.5.0-alpha.0

3 years ago

0.5.0

3 years ago

0.4.1

3 years ago

0.4.0

3 years ago

0.6.1

3 years ago

0.6.0

3 years ago

0.3.5

3 years ago

0.3.4

3 years ago

0.3.3

3 years ago

0.3.2

3 years ago

0.3.1

3 years ago

0.3.0

3 years ago

0.2.0

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago