@workite-io/workite-bpmn-js
v0.1.1
Published
Embeddable Workite modeling distributions based on bpmn-js
Maintainers
Readme
workite-bpmn-js
Embeddable Workite BPMN modeling distributions based on bpmn-js.
Usage
Use the Workite distribution for BPMN workflows with Workite extensions, or the base distribution for engine-neutral BPMN modeling.
Use a pre-packaged distribution
<link rel="stylesheet" href="https://unpkg.com/@workite-io/workite-bpmn-js/dist/assets/workite-modeler.css" />
<script src="https://unpkg.com/@workite-io/workite-bpmn-js/dist/workite-modeler.production.min.js"></script>or install it via npm
import BpmnModeler from '@workite-io/workite-bpmn-js/lib/workite/Modeler';
import '@workite-io/workite-bpmn-js/dist/assets/workite-modeler.css';into your web-application.
var bpmnModeler = new BpmnModeler({
container: '#canvas',
propertiesPanel: {
parent: '#properties'
}
});
try {
await bpmnModeler.importXML(someDiagram);
console.log('success!');
bpmnModeler.get('canvas').zoom('fit-viewport');
} catch (err) {
console.error('something went wrong:', err);
}Checkout the docs to learn more about the available distributions.
Build and Run
Prepare the project by installing all dependencies:
npm installThen, depending on your use-case, you may run any of the following commands:
# build the library and run all tests
npm run all
# spin up a single local Workite modeler instance
npm run start
# run the full development setup
npm run devRelated
workite-bpmn-js builds on these core tools:
- bpmn-js: View and edit BPMN 2.0 diagrams in the browser
- diagram-js: Diagram rendering and editing toolkit
- workite-bpmn-js-properties-panel: Workite BPMN properties panel
- bpmn-js-create-append-anything: A create/append anything extension for bpmn-js
- bpmn-moddle: A BPMN 2.0 diagram reader/writer
- @workite-io/workite-bpmn-moddle: Workite extensions for BPMN 2.0
- @workite-io/workite-bpmn-js-behaviors: Workite-specific modeling behaviors
License
MIT
Uses bpmn-js licensed under the bpmn.io license.
